mirror of
https://github.com/podman-container-tools/podman.git
synced 2026-08-05 00:15:44 +00:00
systems: retrofit dns options test to honor other search domains
Signed-off-by: Aditya R <arajan@redhat.com>
This commit is contained in:
parent
5b91570291
commit
8e30083705
1 changed files with 8 additions and 4 deletions
|
|
@ -664,7 +664,7 @@ EOF
|
|||
"
|
||||
|
||||
CONTAINERS_CONF=$containersconf run_podman run --rm $IMAGE cat /etc/resolv.conf
|
||||
is "$output" "search example.com$nl.*" "correct search domain"
|
||||
is "$output" "search example.com.*" "correct search domain"
|
||||
is "$output" ".*nameserver 1.1.1.1${nl}nameserver $searchIP${nl}nameserver 1.0.0.1${nl}nameserver 8.8.8.8" "nameserver order is correct"
|
||||
|
||||
# create network with dns
|
||||
|
|
@ -673,9 +673,13 @@ EOF
|
|||
run_podman network create --subnet "$subnet.0/24" $netname
|
||||
# custom server overwrites the network dns server
|
||||
CONTAINERS_CONF=$containersconf run_podman run --network $netname --rm $IMAGE cat /etc/resolv.conf
|
||||
is "$output" "search example.com$nl.*" "correct search domain"
|
||||
is "$output" ".*nameserver 1.1.1.1${nl}nameserver $searchIP${nl}nameserver 1.0.0.1${nl}nameserver 8.8.8.8" "nameserver order is correct"
|
||||
|
||||
is "$output" "search example.com.*" "correct search domain"
|
||||
local store=$output
|
||||
if is_netavark; then
|
||||
is "$store" ".*nameserver $subnet.1.*" "integrated dns nameserver is set"
|
||||
else
|
||||
is "$store" ".*nameserver 1.1.1.1${nl}nameserver $searchIP${nl}nameserver 1.0.0.1${nl}nameserver 8.8.8.8" "nameserver order is correct"
|
||||
fi
|
||||
# we should use the integrated dns server
|
||||
run_podman run --network $netname --rm $IMAGE cat /etc/resolv.conf
|
||||
is "$output" "search dns.podman.*" "correct search domain"
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue