summaryrefslogtreecommitdiff
path: root/test/TEST-43-PRIVATEUSER-UNPRIV
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2020-01-03 18:25:51 +0100
committerLennart Poettering <lennart@poettering.net>2020-01-06 13:25:33 +0100
commit6e0ed2865e344e18765c6a3d69c4646015f2a143 (patch)
tree79818cbd8185d03ab61e3505f825c6f8cb071382 /test/TEST-43-PRIVATEUSER-UNPRIV
parentec04aef44225ab0b833b427b43ce8ab69385716d (diff)
downloadsystemd-6e0ed2865e344e18765c6a3d69c4646015f2a143.tar.gz
test: hardcode shell to use
let's make sure we always invoke our commands through /bin/sh, since on some distros su will use /bin/nologin (or whatever is listed in /etc/passwd) as shell otherwise and we don#t want that.
Diffstat (limited to 'test/TEST-43-PRIVATEUSER-UNPRIV')
-rwxr-xr-xtest/TEST-43-PRIVATEUSER-UNPRIV/testsuite.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/TEST-43-PRIVATEUSER-UNPRIV/testsuite.sh b/test/TEST-43-PRIVATEUSER-UNPRIV/testsuite.sh
index cd61dc95c9..158889888e 100755
--- a/test/TEST-43-PRIVATEUSER-UNPRIV/testsuite.sh
+++ b/test/TEST-43-PRIVATEUSER-UNPRIV/testsuite.sh
@@ -7,7 +7,7 @@ systemd-analyze log-level debug
runas() {
declare userid=$1
shift
- su "$userid" -c 'XDG_RUNTIME_DIR=/run/user/$UID "$@"' -- sh "$@"
+ su "$userid" -s /bin/sh -c 'XDG_RUNTIME_DIR=/run/user/$UID exec "$@"' -- sh "$@"
}
runas nobody systemctl --user --wait is-system-running