test/system: podman run update /etc/hosts

This test case is used for covering rhbz#1902979.

Signed-off-by: Alex Jia <ajia@redhat.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
This commit is contained in:
Daniel J Walsh 2022-01-14 07:51:23 -05:00
parent 9686216f9d
commit 13917dfab9
No known key found for this signature in database
GPG Key ID: A2DF901DABE2C028
1 changed files with 7 additions and 0 deletions

View File

@ -818,4 +818,11 @@ EOF
is "$output" ".*The --kernel-memory flag is no longer supported. This flag is a noop." "warn on use of --kernel-memory"
}
# rhbz#1902979 : podman run fails to update /etc/hosts when --uidmap is provided
@test "podman run update /etc/hosts" {
HOST=$(random_string 25)
run_podman run --uidmap 0:10001:10002 --rm --hostname ${HOST} $IMAGE grep ${HOST} /etc/hosts
is "${lines[0]}" ".*${HOST}.*"
}
# vim: filetype=sh