diff options
author | Luca Boccassi <bluca@debian.org> | 2022-03-09 03:07:34 +0100 |
---|---|---|
committer | Luca Boccassi <bluca@debian.org> | 2022-03-10 11:21:03 +0100 |
commit | ea63a260d43c27a6b5b5ae471a8d4617bb7be447 (patch) | |
tree | e6295e1c86974caabcf656b2bd2a9d30f69e47e6 /test/TEST-43-PRIVATEUSER-UNPRIV/test.sh | |
parent | test: set log level of user manager in TEST-43 to debug (diff) | |
download | systemd-ea63a260d43c27a6b5b5ae471a8d4617bb7be447.tar.xz systemd-ea63a260d43c27a6b5b5ae471a8d4617bb7be447.zip |
core: support MountAPIVFS and RootDirectory in user manager
The only piece missing was to somehow make /proc appear in the
new user+mount namespace. It is not possible to mount a new
/proc instance, not even with hidepid=invisible,subset=pid, in
a user namespace unless a PID namespace is created too (and also
at the same time as the other namespaces, it is not possible to
mount a new /proc in a child process that creates a PID namespace
forked from a parent that created a user+mount namespace, it has
to happen at the same time).
Use the host's /proc with a bind-mount as a fallback for this
case. User session services would already run with it, so
nothing is lost.
Diffstat (limited to 'test/TEST-43-PRIVATEUSER-UNPRIV/test.sh')
-rwxr-xr-x | test/TEST-43-PRIVATEUSER-UNPRIV/test.sh | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/TEST-43-PRIVATEUSER-UNPRIV/test.sh b/test/TEST-43-PRIVATEUSER-UNPRIV/test.sh index bb8bc18697..dafcdb58fc 100755 --- a/test/TEST-43-PRIVATEUSER-UNPRIV/test.sh +++ b/test/TEST-43-PRIVATEUSER-UNPRIV/test.sh @@ -3,10 +3,19 @@ set -e TEST_DESCRIPTION="Test PrivateUsers=yes on user manager" +IMAGE_NAME="private-users" # shellcheck source=test/test-functions . "${TEST_BASE_DIR:?}/test-functions" has_user_dbus_socket || exit 0 +command -v mksquashfs >/dev/null 2>&1 || exit 0 + +test_append_files() { + ( + inst_binary unsquashfs + install_verity_minimal + ) +} do_test "$@" |