summaryrefslogtreecommitdiff
path: root/test/TEST-13-NSPAWN-SMOKE
diff options
context:
space:
mode:
authorEvgeny Vereshchagin <evvers@ya.ru>2016-12-05 20:14:05 +0300
committerLennart Poettering <lennart@poettering.net>2016-12-05 18:14:05 +0100
commitc9fd987279a462e406fac6c7ade01da7410bdcd6 (patch)
treefb6d1e06a950f96429a8ca4f256156e6e25cb532 /test/TEST-13-NSPAWN-SMOKE
parente3a7b04848a438f7b5a9a2bf5d7e0e59c5c49a00 (diff)
nspawn: don't hide --bind=/tmp/* mounts (#4824)
Fixes #4789
Diffstat (limited to 'test/TEST-13-NSPAWN-SMOKE')
-rwxr-xr-xtest/TEST-13-NSPAWN-SMOKE/test.sh10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/TEST-13-NSPAWN-SMOKE/test.sh b/test/TEST-13-NSPAWN-SMOKE/test.sh
index 305866ae38..b8b8ec34bd 100755
--- a/test/TEST-13-NSPAWN-SMOKE/test.sh
+++ b/test/TEST-13-NSPAWN-SMOKE/test.sh
@@ -83,6 +83,14 @@ if unshare -U sh -c :; then
is_user_ns_supported=yes
fi
+function check_bind_tmp_path {
+ # https://github.com/systemd/systemd/issues/4789
+ local _root="/var/lib/machines/bind-tmp-path"
+ /create-busybox-container "$_root"
+ >/tmp/bind
+ systemd-nspawn --register=no -D "$_root" --bind=/tmp/bind /bin/sh -c 'test -e /tmp/bind'
+}
+
function run {
if [[ "$1" = "yes" && "$is_v2_supported" = "no" ]]; then
printf "Unified cgroup hierarchy is not supported. Skipping.\n" >&2
@@ -113,6 +121,8 @@ function run {
return 0
}
+check_bind_tmp_path
+
for api_vfs_writable in yes no network; do
run no no $api_vfs_writable
run yes no $api_vfs_writable