[Qa-jenkins-scm] [jenkins.debian.net] 01/01: reproducible Debian: add some sanity checks

Holger Levsen holger at layer-acht.org
Thu Jun 1 23:14:38 UTC 2017


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 0594c1bf2864b71bcb59cf3d876067d6a7a578b5
Author: Holger Levsen <holger at layer-acht.org>
Date:   Fri Jun 2 01:14:32 2017 +0200

    reproducible Debian: add some sanity checks
    
    Signed-off-by: Holger Levsen <holger at layer-acht.org>
---
 init_node | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/init_node b/init_node
index 89a1fbb..a96cdbb 100755
--- a/init_node
+++ b/init_node
@@ -5,6 +5,17 @@
 # released under the GPLv=2
 #
 # initial setup for new build nodes
+# - this script assumes that the user running it has unlimited sudo powers…
+
+# let's check our assumptions first…
+if [ $(sudo id -u) -ne 0 ] ; then
+	echo we need sudo… exiting.
+	exit 1
+elif [ $(id -u) -eq 0 ] ; then
+	echo please dont run this as root… exiting.
+	exit 1
+fi
+
 
 START=$(date +'%s')
 GIT_REPO="git://anonscm.debian.org/qa/jenkins.debian.net.git"

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