diff --git a/slave_scripts/wait_for_puppet.sh b/slave_scripts/wait_for_puppet.sh index 9f6bdd02..4dfc6589 100755 --- a/slave_scripts/wait_for_puppet.sh +++ b/slave_scripts/wait_for_puppet.sh @@ -11,10 +11,10 @@ HOSTS=$@ echo "Jenkins: Waiting for puppet to complete on all nodes" DONE=0 while [ $DONE != 1 ]; do - DONE=0 + DONE=1 for hostname in $HOSTS do - if (grep "$hostname $FINISH_RE" $LOGFILE >/dev/null); then DONE=1; fi + if !(grep "$hostname $FINISH_RE" $LOGFILE >/dev/null); then DONE=0; fi done sleep 5 done