[Reproducible-commits] [misc] 01/02: prebuilder: make user switch compatible with pbuilder >= 0.217

Jérémy Bobbio lunar at moszumanska.debian.org
Thu Nov 19 12:02:01 UTC 2015


This is an automated email from the git hooks/post-receive script.

lunar pushed a commit to branch master
in repository misc.

commit cb717d3bb08ecdb6c31686bf84596d5987327bcb
Author: Jérémy Bobbio <lunar at debian.org>
Date:   Thu Nov 19 12:00:13 2015 +0000

    prebuilder: make user switch compatible with pbuilder >= 0.217
---
 prebuilder/pbuilderhooks/A02_user | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/prebuilder/pbuilderhooks/A02_user b/prebuilder/pbuilderhooks/A02_user
index f1fc28e..a3c8ceb 100755
--- a/prebuilder/pbuilderhooks/A02_user
+++ b/prebuilder/pbuilderhooks/A02_user
@@ -7,9 +7,11 @@ echo "I: adding another test user for reproducibility"
 NEWUID=$(($(id -u pbuilder) + 1))
 NEWGID=$(($(id -g pbuilder) + 1))
 
+BUILDDIR=${BUILDDIR:-/tmp/buildd} # stay compatible with pbuilder << 0.217
+
 groupadd -g "$NEWGID" -o another-group
-useradd -g another-group -u "$NEWUID" -d /tmp/buildd -o another-user
-chown -R "$NEWUID:$NEWGID" /tmp/buildd
+useradd -g another-group -u "$NEWUID" -d "$BUILDDIR" -o another-user
+chown -R "$NEWUID:$NEWGID" "$BUILDDIR"
 
 apt-get install sudo
 cat >/etc/sudoers.d/pbuser <<EOF

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/reproducible/misc.git



More information about the Reproducible-commits mailing list