From 49e25646f08cec89adc3db015c58f8edcc5a2b95 Mon Sep 17 00:00:00 2001 From: Holger Levsen Date: Wed, 16 Sep 2015 13:24:05 +0200 Subject: reproducible: unregister build if the node is down --- bin/reproducible_build.sh | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'bin') diff --git a/bin/reproducible_build.sh b/bin/reproducible_build.sh index d6c4578e..da10dd5e 100755 --- a/bin/reproducible_build.sh +++ b/bin/reproducible_build.sh @@ -264,7 +264,14 @@ handle_reproducible() { fi } +unregister_build() { + # unregister this build so it will immeditiatly tried again + sqlite3 -init $INIT ${PACKAGES_DB} "UPDATE schedule SET date_build_started='', builder='' WHERE package_id='$SRCPKGID'" + NOTIFY="" +} + handle_unhandled() { + unregister_build MESSAGE="$BUILD_URL met an unhandled $1, please investigate." echo "$MESSAGE" irc_msg "$MESSAGE" @@ -540,6 +547,7 @@ remote_build() { # abort job if host is down if [ $RESULT -ne 0 ] ; then echo "$(date -u) - $NODE seems to be down, sleeping 23min before aborting this job." + unregister_build sleep 23m exec /srv/jenkins/bin/abort.sh fi -- cgit v1.2.3-54-g00ecf