diff options
author | Ed Santiago <santiago@redhat.com> | 2020-08-25 07:18:05 -0600 |
---|---|---|
committer | Ed Santiago <santiago@redhat.com> | 2020-08-25 07:26:23 -0600 |
commit | a60b4cc1d8d06782b4df13a08ea6440e27809d0b (patch) | |
tree | 4f65c43d418fff92267e19a3dccf5c2328e3aeaa | |
parent | 024f47068a894907ee47b1b90c86090a00586940 (diff) | |
download | podman-a60b4cc1d8d06782b4df13a08ea6440e27809d0b.tar.gz podman-a60b4cc1d8d06782b4df13a08ea6440e27809d0b.tar.bz2 podman-a60b4cc1d8d06782b4df13a08ea6440e27809d0b.zip |
run test: use explicit uid/gid
Fixes Fedora gating test failure: if the host tests are running
under UID 1000, --userns=keep-id will (of course) add current
user as 1000, and the in-container 'adduser' will assign 1001.
To prevent that, assign UID 4242 (and hope that that's not
our calling user's UID).
Signed-off-by: Ed Santiago <santiago@redhat.com>
-rw-r--r-- | test/system/030-run.bats | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/system/030-run.bats b/test/system/030-run.bats index 12c82bc4c..5e0ab3d6a 100644 --- a/test/system/030-run.bats +++ b/test/system/030-run.bats @@ -286,10 +286,10 @@ echo $rand | 0 | $rand cid="$output" gecos="$(random_string 6) $(random_string 8)" - run_podman exec --user root $cid adduser -D -g "$gecos" -s /bin/sh newuser3 + run_podman exec --user root $cid adduser -u 4242 -G ping -D -g "$gecos" -s /bin/sh newuser3 is "$output" "" "output from adduser" run_podman exec $cid tail -1 /etc/passwd - is "$output" "newuser3:x:1000:1000:$gecos:/home/newuser3:/bin/sh" \ + is "$output" "newuser3:x:4242:999:$gecos:/home/newuser3:/bin/sh" \ "newuser3 added to /etc/passwd in container" run_podman exec $cid touch /stop |