[Qa-jenkins-scm] [jenkins.debian.net] 01/11: Revert "reproducible/openwrt|lede: fixup node_wrapper usage"

Holger Levsen holger at layer-acht.org
Tue Aug 2 14:25:01 UTC 2016


This is an automated email from the git hooks/post-receive script.

holger pushed a commit to branch master
in repository jenkins.debian.net.

commit 8b2041c98b2a9baab95174dc4b34711e8817d2c7
Author: Alexander Couzens <lynxis at fe80.eu>
Date:   Sat Jul 30 21:53:50 2016 +0200

    Revert "reproducible/openwrt|lede: fixup node_wrapper usage"
    
    This reverts commit 8d586d5c9968778c934996aa59626635fc20b99f.
    
    Signed-off-by: Holger Levsen <holger at layer-acht.org>
---
 bin/jenkins_node_wrapper.sh        |  8 ++++----
 bin/reproducible_lede.sh           |  7 ++++---
 bin/reproducible_openwrt.sh        |  7 ++++---
 bin/reproducible_openwrt_common.sh | 13 +++++++------
 4 files changed, 19 insertions(+), 16 deletions(-)

diff --git a/bin/jenkins_node_wrapper.sh b/bin/jenkins_node_wrapper.sh
index 15c0e0d..12f7085 100755
--- a/bin/jenkins_node_wrapper.sh
+++ b/bin/jenkins_node_wrapper.sh
@@ -117,10 +117,10 @@ elif [[ "$*" =~ ^reproducible_setup_schroot_experimental_.*_.* ]] ; then
 	exec /srv/jenkins/bin/schroot-create.sh reproducible reproducible-experimental experimental ; croak "Exec failed";
 elif [[ "$*" =~ ^reproducible_coreboot ]] ; then
 	exec /srv/jenkins/bin/reproducible_coreboot.sh ; croak "Exec failed";
-elif [ "$1" = "/srv/jenkins/bin/reproducible_openwrt.sh" ] && ( [ "$2" = "master" ] || [ "$2" = "1" ] || [ "$2" = "2" ] ) ; then
-	exec /srv/jenkins/bin/reproducible_openwrt.sh "$2" "$3" "$4" "$5" "$6" "$7" "$8" ; croak "Exec failed";
-elif [ "$1" = "/srv/jenkins/bin/reproducible_lede.sh" ] && ( [ "$2" = "master" ] || [ "$2" = "1" ] || [ "$2" = "2" ] ) ; then
-	exec /srv/jenkins/bin/reproducible_lede.sh "$2" "$3" "$4" "$5" "$6" "$7" "$8" ; croak "Exec failed";
+elif [[ "$*" =~ ^reproducible_openwrt ]] ; then
+	exec /srv/jenkins/bin/reproducible_openwrt.sh master ; croak "Exec failed";
+elif [[ "$*" =~ ^reproducible_lede ]] ; then
+	exec /srv/jenkins/bin/reproducible_lede.sh master ; croak "Exec failed";
 elif [[ "$*" =~ ^reproducible_netbsd ]] ; then
 	exec /srv/jenkins/bin/reproducible_netbsd.sh ; croak "Exec failed";
 elif [[ "$*" =~ ^reproducible_freebsd ]] ; then
diff --git a/bin/reproducible_lede.sh b/bin/reproducible_lede.sh
index b7e7a9f..534056c 100755
--- a/bin/reproducible_lede.sh
+++ b/bin/reproducible_lede.sh
@@ -1,6 +1,6 @@
 #!/bin/bash
 
-# Copyright 2014-2016 Holger Levsen <holger at layer-acht.org>
+# Copyright 2014-2015 Holger Levsen <holger at layer-acht.org>
 #         © 2015 Reiner Herrmann <reiner at reiner-h.de>
 #           2016 Alexander Couzens <lynxis at fe80.eu>
 # released under the GPLv=2
@@ -20,8 +20,9 @@ set -e
 # * it's called from the reproducible_wrapper when running on the master
 # * it's called from reproducible_opewnrt_common when doing remote builds
 case $1 in
-	1|2)
-		# execute build 1 or 2
+	slave)
+		# execute the slave
+		shift
 		$@
 		exit $?
 	;;
diff --git a/bin/reproducible_openwrt.sh b/bin/reproducible_openwrt.sh
index 495b053..d343590 100755
--- a/bin/reproducible_openwrt.sh
+++ b/bin/reproducible_openwrt.sh
@@ -1,6 +1,6 @@
 #!/bin/bash
 
-# Copyright 2014-2016 Holger Levsen <holger at layer-acht.org>
+# Copyright 2014-2015 Holger Levsen <holger at layer-acht.org>
 #         © 2015 Reiner Herrmann <reiner at reiner-h.de>
 #           2016 Alexander Couzens <lynxis at fe80.eu>
 # released under the GPLv=2
@@ -20,8 +20,9 @@ set -e
 # * it's called from the reproducible_wrapper when running on the master
 # * it's called from reproducible_opewnrt_common when doing remote builds
 case $1 in
-	1|2)
-		# execute build 1 or 2
+	slave)
+		# execute the slave
+		shift
 		$@
 		exit $?
 	;;
diff --git a/bin/reproducible_openwrt_common.sh b/bin/reproducible_openwrt_common.sh
index 32a814e..b3f4e31 100644
--- a/bin/reproducible_openwrt_common.sh
+++ b/bin/reproducible_openwrt_common.sh
@@ -1,6 +1,6 @@
 #!/bin/bash
 
-# Copyright 2014-2016 Holger Levsen <holger at layer-acht.org>
+# Copyright 2014-2015 Holger Levsen <holger at layer-acht.org>
 #         © 2015 Reiner Herrmann <reiner at reiner-h.de>
 #           2016 Alexander Couzens <lynxis at fe80.eu>
 # released under the GPLv=2
@@ -258,20 +258,21 @@ build_two_times() {
 	TMPDIR_B1=$(ssh $HOST_B1 mktemp --tmpdir=/srv/workspace/chroots/ -d -t rbuild-lede-build-XXXXXXXX)
 	# TODO check tmpdir exist
 
-	ssh $HOST_B1 $0 openwrt_build $TYPE $RUN $TARGET $CONFIG $TMPDIR_B1
+	SCRIPT="$0 slave"
+	ssh $HOST_B1 $SCRIPT openwrt_build $TYPE $RUN $TARGET $CONFIG $TMPDIR_B1
 
 	# rsync back
 	# copy logs and images
 	rsync -a $HOST_B1:$TMPDIR_B1/$RUN/ $TMPDIR/$RUN/
 
-	ssh $HOST_B1 $0 openwrt_get_banner $TMPDIR_B1 $TYPE > $BANNER_HTML
-	ssh $HOST_B1 $0 openwrt_cleanup_tmpdirs $TMPDIR_B1
+	ssh $HOST_B1 $SCRIPT openwrt_get_banner $TMPDIR_B1 $TYPE > $BANNER_HTML
+	ssh $HOST_B1 $SCRIPT openwrt_cleanup_tmpdirs $TMPDIR_B1
 
 	## HOST_B2
 	RUN=b2
 	TMPDIR_B2=$(ssh $HOST_A mktemp --tmpdir=/srv/workspace/chroots/ -d -t rbuild-lede-build-XXXXXXXX)
-	ssh $HOST_B2 $0 openwrt_build $TYPE $RUN $TARGET $CONFIG $TMPDIR_B2
+	ssh $HOST_B2 $SCRIPT openwrt_build $TYPE $RUN $TARGET $CONFIG $TMPDIR_B2
 
 	rsync -a $HOST_B2:$TMPDIR_B2/$RUN/ $TMPDIR/$RUN/
-	ssh $HOST_B2 $0 openwrt_cleanup_tmpdirs $TMPDIR_B2
+	ssh $HOST_B2 $SCRIPT openwrt_cleanup_tmpdirs $TMPDIR_B2
 }

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/qa/jenkins.debian.net.git



More information about the Qa-jenkins-scm mailing list