[Qa-jenkins-scm] [jenkins.debian.net] 01/01: allow arbitrary commands only for all hosts

Holger Levsen holger at layer-acht.org
Mon Dec 19 01:38:16 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 a66f991dc110fd868569640c1d8ea61c06699157
Author: Holger Levsen <holger at layer-acht.org>
Date:   Mon Dec 19 02:36:41 2016 +0100

    allow arbitrary commands only for all hosts
    
    Signed-off-by: Holger Levsen <holger at layer-acht.org>
---
 deploy_everywhere | 11 +++++++----
 1 file changed, 7 insertions(+), 4 deletions(-)

diff --git a/deploy_everywhere b/deploy_everywhere
index f50abdc..855eed0 100755
--- a/deploy_everywhere
+++ b/deploy_everywhere
@@ -15,6 +15,7 @@
 
 # useful things:
 # ./deploy_everywhere all		- deploy on all nodes (and handle 398 days hosts properly)
+# ./deploy_everywhere all $foo		- run "$foo" on all nodes (and handle 398 days hosts properly)
 # ./deploy_everywhere 			- deploy on jenkins only
 # ./deploy_everywhere jenkins		- deploy on jenkins only
 # ./deploy_everywhere jenkins pb10	- deploy on jenkins and pb10
@@ -89,6 +90,12 @@ if [ "$1" = "all" ] ; then
 	echo -n "Running j.d.n.git updates on $HOSTS now"
 	# reset_clock can be false as update_jdn.sh sets the time
 	reset_clock=false
+	shift
+	if [ -z "$1" ] ; then
+		real_command="$@"
+		echo -n "Running '$real_command' on $HOSTS now."
+		real_command="$@ && echo '__reallyreally=ok__'"
+	fi
 elif [ "$1" = "upgrade" ] ; then
 	real_command="export LANG=C && sudo apt-get update && sudo apt-get upgrade && sudo apt-get dist-upgrade && sudo apt-get clean"
 	shift
@@ -125,10 +132,6 @@ elif [ "$1" = "" ] || [ "$1" = "jenkins" ] ; then
 		esac
 	done
 	echo -n "Running j.d.n.git ('$real_command') updates on $HOSTS now"
-else
-	real_command="$@"
-	echo -n "Running '$real_command' on $HOSTS now."
-	real_command="$@ && echo '__reallyreally=ok__'"
 fi
 BG=""
 

-- 
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