From a23507bf206c2dcfcb0f65bc26ab24d2e0bb2999 Mon Sep 17 00:00:00 2001 From: Andreas Baumann Date: Wed, 27 Nov 2019 16:49:04 +0100 Subject: added a simpler graceful stop version --- lib/load-configuration | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'lib/load-configuration') diff --git a/lib/load-configuration b/lib/load-configuration index b6756c1..08ca4bf 100755 --- a/lib/load-configuration +++ b/lib/load-configuration @@ -28,6 +28,13 @@ if [ "$(hostname)" = 'buildmaster.archlinux32.org' ]; then fi else i_am_the_master=false + if [ -f '/tmp/do-not-run-build-slave' ]; then + >&2 echo 'build slave is on halt.' + >&2 echo 'I will stop now.' + # non-zero exit code to signal systemctl that the process should not + # be restarted automatically + exit 1 + fi fi # dirty hack to get this stuff debugable from a bash -- cgit v1.2.3