mirror of
https://github.com/troglobit/finit.git
synced 2026-10-05 15:23:31 +07:00
test: Reset PS env vars in test environment
Signed-off-by: Jacques de Laval <jacques@de-laval.se>
This commit is contained in:
@@ -17,6 +17,11 @@ nsenter=$(which nsenter)
|
||||
chroot=$(which chroot)
|
||||
|
||||
export PATH=/sbin:/bin
|
||||
export PS1='\w \$ '
|
||||
export PS2='> '
|
||||
export PS3='#? '
|
||||
export PS4='+ '
|
||||
|
||||
"$nsenter" \
|
||||
--preserve-credentials \
|
||||
--user \
|
||||
|
||||
@@ -10,9 +10,14 @@ TESTS_ROOT="$(pwd)/${TEST_DIR}/test_root"
|
||||
unshare=$(which unshare)
|
||||
chroot=$(which chroot)
|
||||
|
||||
export PATH=/sbin:/bin
|
||||
export PS1='\w \$ '
|
||||
export PS2='> '
|
||||
export PS3='#? '
|
||||
export PS4='+ '
|
||||
|
||||
# Not supported by Busybox unshare:
|
||||
# --cgroup --time
|
||||
export PATH=/sbin:/bin
|
||||
exec "$unshare" \
|
||||
--user --map-root-user \
|
||||
--fork --pid --mount-proc \
|
||||
|
||||
Reference in New Issue
Block a user