Skip to content
Commits on Source (3)
#!/bin/bash
# vim: set noexpandtab:
# Copyright 2012-2017 Holger Levsen <holger@layer-acht.org>
# 2018 Mattia Rizzolo <mattia@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"
......
......@@ -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";
......