mirror of
https://gitlab.alpinelinux.org/alpine/abuild.git
synced 2025-01-03 13:12:15 +00:00
abuild-rootbld: clear environment for bwrap container
Otherwise, user-set environment variables can leak into the container and cause spurious build/test failures. A common example is the value of the SHELL environment variable which is used by a lot of software. Outside of the bwrap container I use ksh and my SHELL environment variable points to /bin/ksh, however, inside the container /bin/ksh is not available and hence software relying on $SHELL doesn't work properly. This can cause annoying to debug test failures, e.g. !43430.
This commit is contained in:
parent
489fc06e40
commit
1582617eb8
@ -2508,6 +2508,10 @@ rootbld() {
|
||||
--bind "$REPODEST" "$REPODEST" \
|
||||
--hostname "build-$buildhost-$CARCH" \
|
||||
--chdir "$startdir" \
|
||||
--clearenv \
|
||||
--setenv HOME "$HOME" \
|
||||
--setenv SOURCE_DATE_EPOCH "$SOURCE_DATE_EPOCH" \
|
||||
--setenv ABUILD_LAST_COMMIT "$ABUILD_LAST_COMMIT" \
|
||||
--setenv PATH ${USE_CCACHE:+/usr/lib/ccache/bin:}/bin:/usr/bin:/sbin:/usr/sbin \
|
||||
--setenv FAKEROOTDONTTRYCHOWN 1 \
|
||||
--unsetenv CBUILD \
|
||||
|
Loading…
Reference in New Issue
Block a user