summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xbin/reproducible_worker.sh9
1 files changed, 7 insertions, 2 deletions
diff --git a/bin/reproducible_worker.sh b/bin/reproducible_worker.sh
index f37ca689..c0a9d83e 100755
--- a/bin/reproducible_worker.sh
+++ b/bin/reproducible_worker.sh
@@ -32,8 +32,13 @@ while true ; do
SERVICE="reproducible_build@startup.service"
RUNNING=$(systemctl show $SERVICE|grep ^SubState|cut -d "=" -f2)
if [ "$RUNNING" != "running" ] ; then
- echo "$(date --utc) - '$SERVICE' not running, thus stopping this."
- break
+ # sometimes systemctl requests time out… handle that gracefully
+ sleep 23
+ RUNNING=$(systemctl show $SERVICE|grep ^SubState|cut -d "=" -f2)
+ if [ "$RUNNING" != "running" ] ; then
+ echo "$(date --utc) - '$SERVICE' not running, thus stopping this."
+ break
+ fi
fi
# sleep up to 2.3 seconds (additionally to the random sleep reproducible_build.sh does anyway)