From 734bbb8ecfedf4dd07fd9cb12ad4eb082fb10f87 Mon Sep 17 00:00:00 2001 From: samuel Date: Tue, 9 May 2023 15:23:43 +0200 Subject: [PATCH] [Fix] Check runner sock already running only when starting --- src/runner.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/runner.sh b/src/runner.sh index 66f6759..4b39d6b 100755 --- a/src/runner.sh +++ b/src/runner.sh @@ -433,10 +433,6 @@ main() ( fail "Directory of runner_sock='${runner_sock}' is not writable." \ "${err_runner_sock_dir_not_writable}" fi - if [ -e "${runner_sock}" ]; then - fail "Sock deployer_sock='${runner_sock}' is already in use." \ - "${err_runner_sock_already_in_use}" - fi if [ -z "${runner_cloning_dir}" ]; then fail "Variable runner_cloning_dir is empty." \ @@ -511,6 +507,10 @@ main() ( fail "Sock deployer_sock='${deployer_sock}' does not exist." \ "${err_deployer_sock_not_exist}" fi + if [ -e "${runner_sock}" ]; then + fail "Sock deployer_sock='${runner_sock}' is already in use." \ + "${err_runner_sock_already_in_use}" + fi # Set right access in background after nc listen. (