summaryrefslogtreecommitdiffstats
path: root/bin/schroot-create.sh
diff options
context:
space:
mode:
authorHolger Levsen <holger@layer-acht.org>2014-10-18 19:28:10 +0200
committerHolger Levsen <holger@layer-acht.org>2014-10-18 19:54:52 +0200
commit7aaed3108923a756b9418226c94469961990ce5c (patch)
treecfba00e8c0d1aaa2232d8af2d9ddc23c384e5586 /bin/schroot-create.sh
parent220af83f26581f2c0c9bf682ccbf70f43b0dc8b5 (diff)
downloadjenkins.debian.net-7aaed3108923a756b9418226c94469961990ce5c.tar.xz
reproducible: run debbindiff from within a(nother) sid schroot (created by another job)
Diffstat (limited to 'bin/schroot-create.sh')
-rwxr-xr-xbin/schroot-create.sh13
1 files changed, 7 insertions, 6 deletions
diff --git a/bin/schroot-create.sh b/bin/schroot-create.sh
index f59010b1..5f31e3cd 100755
--- a/bin/schroot-create.sh
+++ b/bin/schroot-create.sh
@@ -53,6 +53,11 @@ bootstrap() {
echo "deb-src $MIRROR $DISTRO main" | sudo tee -a $CHROOT_TARGET/etc/apt/sources.list > /dev/null
echo "${BACKPORTS}" | sudo tee -a $CHROOT_TARGET/etc/apt/sources.list >/dev/null
echo "${BACKPORTSSRC}" | sudo tee -a $CHROOT_TARGET/etc/apt/sources.list >/dev/null
+
+ sudo chroot $CHROOT_TARGET apt-get update
+ if [ -n "$1" ] ; then
+ sudo chroot $CHROOT_TARGET apt-get install -y --no-install-recommends "$@"
+ fi
}
cleanup() {
@@ -61,7 +66,7 @@ cleanup() {
fi
}
trap cleanup INT TERM EXIT
-bootstrap
+bootstrap $@
trap - INT TERM EXIT
@@ -91,8 +96,4 @@ sudo tee /etc/schroot/chroot.d/jenkins-"$TARGET" <<-__END__
union-type=aufs
__END__
-schroot --directory /root -c "source:jenkins-$TARGET" -u root -- apt-get update
-if [ -n "$1" ]
-then
- schroot --directory /root -c "source:jenkins-$TARGET" -u root -- apt-get install -y --no-install-recommends "$@"
-fi
+