From: Holger Levsen Date: Thu, 25 Oct 2012 11:17:53 +0000 (+0200) Subject: only rsync images for non-development builds X-Git-Url: https://git.uhu-banane.de/?a=commitdiff_plain;h=12d8b2bae448e1f878917a195b208c9997dcb6a9;p=profitbricks%2Fjenkins-build-scripts.git only rsync images for non-development builds --- diff --git a/liveboot_build.sh b/liveboot_build.sh index 4f97d46..bd97392 100755 --- a/liveboot_build.sh +++ b/liveboot_build.sh @@ -59,11 +59,15 @@ rm $BUILD_SCRIPT BUILD_END=$(date +%s) $SCRIPTSDIR/liveboot2db.py $JOB_NAME $BUILD_NUMBER $REQUEST_ID $BUILD_START $BUILD_END "successful" -# FIXME: too much sudo here... -cd /srv/build/liveboot/builds -sudo mv *-* /srv/mirror/liveboot -cd /srv/build/ -sudo rm liveboot -Rf +if [ "$GIT_BRANCH" = "master" ] ; then + # FIXME: too much sudo here... + cd /srv/build/liveboot/builds + sudo mv *-* /srv/mirror/liveboot + cd /srv/build/ + sudo rm liveboot -Rf +else + echo "Development build, no rsyncing of images." +fi # # remove trap to not set failure at the end :)