]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
test/docker-test: Fix permissions issue when using podman
authorBrad Hubbard <bhubbard@redhat.com>
Tue, 22 Sep 2020 00:28:09 +0000 (10:28 +1000)
committerBrad Hubbard <bhubbard@redhat.com>
Tue, 22 Sep 2020 00:28:09 +0000 (10:28 +1000)
Signed-off-by: Brad Hubbard <bhubbard@redhat.com>
src/test/docker-test-helper.sh

index 80771eb14dd4369582f7b07c13e676cd1f667902..8459962758990accebb361f5d24543c5d4382d4d 100755 (executable)
@@ -126,6 +126,9 @@ function run_in_docker() {
     local cmd="$dockercmd run $opts --rm --name $image --privileged $ccache"
     cmd+=" --volume $downstream:$downstream"
     cmd+=" --volume $upstream:$upstream"
+    if test "$dockercmd" = "podman" ; then
+        cmd+=" --userns=keep-id"
+    fi
     local status=0
     if test "$script" = "SHELL" ; then
         $cmd --tty --interactive --workdir $downstream $user $image bash