aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorDaniel J Walsh <dwalsh@redhat.com>2022-02-01 15:58:27 -0500
committerMatthew Heon <matthew.heon@pm.me>2022-02-03 16:21:26 -0500
commit48f10e1d0d5873c7baa0613156294307f8c9942d (patch)
treeb750ce0e49a68f2282b7bdb602334e2696087cdd /test
parent938d5152ca6a2e347cd62aaba25c178fd077a235 (diff)
downloadpodman-48f10e1d0d5873c7baa0613156294307f8c9942d.tar.gz
podman-48f10e1d0d5873c7baa0613156294307f8c9942d.tar.bz2
podman-48f10e1d0d5873c7baa0613156294307f8c9942d.zip
Move each search dns to its own line
Alpine does not seem to use search correctly when there are multiple search domains on the same line. It only uses the first with the advent. When podman runs within a separate network we are appending on dns.podman as a search, if you add a search domain, then this causes the local search on network to fail. Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
Diffstat (limited to 'test')
-rw-r--r--test/system/500-networking.bats7
1 files changed, 6 insertions, 1 deletions
diff --git a/test/system/500-networking.bats b/test/system/500-networking.bats
index 9f70c1c6c..e54b8d26a 100644
--- a/test/system/500-networking.bats
+++ b/test/system/500-networking.bats
@@ -597,7 +597,7 @@ load helpers
searchIP="100.100.100.100"
cat >$containersconf <<EOF
[containers]
- dns_searches = [ "example.com"]
+ dns_searches = [ "example.com", "test1.com"]
dns_servers = [
"1.1.1.1",
"$searchIP",
@@ -605,9 +605,14 @@ load helpers
"8.8.8.8",
]
EOF
+export searchDNS="search example.com
+search test1.com
+search a.b"
CONTAINERS_CONF=$containersconf run_podman run --rm $IMAGE grep "example.com" /etc/resolv.conf
CONTAINERS_CONF=$containersconf run_podman run --rm $IMAGE grep $searchIP /etc/resolv.conf
is "$output" "nameserver $searchIP" "Should only be one $searchIP not multiple"
+ CONTAINERS_CONF=$containersconf run_podman run --dns-search a.b --rm $IMAGE grep search /etc/resolv.conf
+ is "$output" "$searchDNS" "Searches should be on different lines"
}
# vim: filetype=sh