From 3a008c15953b641a1122eb5de708652a78be8c09 Mon Sep 17 00:00:00 2001 From: Dominik Meyer Date: Fri, 16 Aug 2024 20:08:35 +0200 Subject: [PATCH] feat: support setting amanda config by env variable closes #51 --- server/scripts/entryPoint.sh | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/server/scripts/entryPoint.sh b/server/scripts/entryPoint.sh index 778fba8..6c19d2e 100644 --- a/server/scripts/entryPoint.sh +++ b/server/scripts/entryPoint.sh @@ -1,8 +1,13 @@ #!/bin/bash -amcleanup -k server -amcheck server -amdump server -amstatus server +if [ -z ${AMANDA_CONFIG} ]; then + echo "it set best practise to set the AMANDA_CONFIG environment variable" + AMANDA_CONFIG="server" +fi + +amcleanup -k ${AMANDA_CONFIG} +amcheck ${AMANDA_CONFIG} +amdump ${AMANDA_CONFIG} +amstatus ${AMANDA_CONFIG} exit 0 \ No newline at end of file