From a3c5a847e511bfe81f3072f3898d1fba9701ee6e Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Wed, 6 Sep 2023 15:20:07 +0100 Subject: [PATCH] fix(start): lock file created before check Even if check fails a lock file will be generated to allow monitor to run --- lgsm/modules/command_start.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lgsm/modules/command_start.sh b/lgsm/modules/command_start.sh index 963815b1b..b2f46855d 100644 --- a/lgsm/modules/command_start.sh +++ b/lgsm/modules/command_start.sh @@ -181,13 +181,13 @@ fn_start_tmux() { echo -en "\n" } -check.sh - # If user ran the start command monitor will become enabled. if [ "${firstcommandname}" == "START" ] || [ "${firstcommandname}" == "RESTART" ]; then date '+%s' > "${lockdir:?}/${selfname}-monitoring.lock" fi +check.sh + # If the server already started dont start again. if [ "${status}" != "0" ]; then fn_print_dots "${servername}"