[Qa-jenkins-scm] [Git][qa/jenkins.debian.net][master] 3 commits: chroot-installation: umount /proc only if mounted

Mattia Rizzolo gitlab at salsa.debian.org
Thu May 31 22:56:10 BST 2018


Mattia Rizzolo pushed to branch master at Debian QA / jenkins.debian.net


Commits:
5f895554 by Mattia Rizzolo at 2018-05-31T23:50:09+02:00
chroot-installation: umount /proc only if mounted

Signed-off-by: Mattia Rizzolo <mattia at debian.org>

- - - - -
53a58846 by Mattia Rizzolo at 2018-05-31T23:53:25+02:00
chroot-installation: diable debug: it has been enabled ages ago and it's now only cluttering the output

Signed-off-by: Mattia Rizzolo <mattia at debian.org>

- - - - -
a2c2d2d8 by Mattia Rizzolo at 2018-05-31T23:54:52+02:00
jenkins_node_wrapper: do the match only on the first parameter, not all the arguments

Signed-off-by: Mattia Rizzolo <mattia at debian.org>

- - - - -


2 changed files:

- bin/chroot-installation.sh
- bin/jenkins_node_wrapper.sh


Changes:

=====================================
bin/chroot-installation.sh
=====================================
--- a/bin/chroot-installation.sh
+++ b/bin/chroot-installation.sh
@@ -1,9 +1,11 @@
 #!/bin/bash
+# vim: set noexpandtab:
 
 # Copyright 2012-2017 Holger Levsen <holger at layer-acht.org>
+#           2018      Mattia Rizzolo <mattia at debian.org>
 # released under the GPLv=2
 
-DEBUG=true
+DEBUG=false
 . /srv/jenkins/bin/common-functions.sh
 common_init "$@"
 set -e
@@ -38,7 +40,9 @@ cleanup_all() {
 		echo "HALP. CHROOT_TARGET = $CHROOT_TARGET"
 		exit 1
 	fi
-	sudo umount -l $CHROOT_TARGET/proc || fuser -mv $CHROOT_TARGET/proc
+	if mountpoint -q "$CHROOT_TARGET/proc" ; then
+		sudo umount -l "$CHROOT_TARGET/proc"
+	fi
 	sudo rm -rf --one-file-system $CHROOT_TARGET || fuser -mv $CHROOT_TARGET
 	rm -f $TMPLOG
 	echo "\$1 = $1"


=====================================
bin/jenkins_node_wrapper.sh
=====================================
--- a/bin/jenkins_node_wrapper.sh
+++ b/bin/jenkins_node_wrapper.sh
@@ -73,9 +73,9 @@ elif [[ "$*" =~ ^rebootstrap_.* ]] ; then
 	REBOOTSTRAPSH="/srv/jenkins/bin/rebootstrap.sh $@"
 	export LC_ALL=C
 	exec $REBOOTSTRAPSH; croak "Exec failed";
-elif [[ "$*" =~ ^chroot-installation_.*maintenance$ ]]; then
+elif [[ "$1" =~ ^chroot-installation_.*maintenance$ ]]; then
 	shift ; exec /srv/jenkins/bin/maintenance.sh $@ ; croak "Exec failed"
-elif [[ "$*" =~ ^chroot-installation_.* ]]; then
+elif [[ "$1" =~ ^chroot-installation_.* ]]; then
 	shift ; exec /srv/jenkins/bin/chroot-installation.sh $@ ; croak "Exec failed"
 elif [ "$*" = "reproducible_html_nodes_info" ] ; then
 	exec /srv/jenkins/bin/reproducible_info.sh ; croak "Exec failed";



View it on GitLab: https://salsa.debian.org/qa/jenkins.debian.net/compare/b6bb5467f9c588cc22e0aa17f12d8a2d60e4cc48...a2c2d2d862e1356835902e64fd0e7fb7b3da604b

-- 
View it on GitLab: https://salsa.debian.org/qa/jenkins.debian.net/compare/b6bb5467f9c588cc22e0aa17f12d8a2d60e4cc48...a2c2d2d862e1356835902e64fd0e7fb7b3da604b
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/qa-jenkins-scm/attachments/20180531/249da4b0/attachment-0001.html>


More information about the Qa-jenkins-scm mailing list