From 90050671b71cd4629b27809055bd562ab76c4460 Mon Sep 17 00:00:00 2001 From: Paul Holzinger Date: Wed, 24 Feb 2021 10:41:56 +0100 Subject: Add dns search domains from cni response to resolv.conf This fixes slow local host name lookups. see containers/dnsname#57 Signed-off-by: Paul Holzinger --- test/e2e/run_networking_test.go | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'test/e2e') diff --git a/test/e2e/run_networking_test.go b/test/e2e/run_networking_test.go index a6237a49a..0e6e636bc 100644 --- a/test/e2e/run_networking_test.go +++ b/test/e2e/run_networking_test.go @@ -766,4 +766,18 @@ var _ = Describe("Podman run networking", func() { session.WaitWithDefaultTimeout() Expect(session.ExitCode()).To(BeZero()) }) + + It("podman run check dnsname adds dns search domain", func() { + Skip("needs dnsname#57") + net := "dnsname" + stringid.GenerateNonCryptoID() + session := podmanTest.Podman([]string{"network", "create", net}) + session.WaitWithDefaultTimeout() + defer podmanTest.removeCNINetwork(net) + Expect(session.ExitCode()).To(BeZero()) + + session = podmanTest.Podman([]string{"run", "--network", net, ALPINE, "cat", "/etc/resolv.conf"}) + session.WaitWithDefaultTimeout() + Expect(session.ExitCode()).To(BeZero()) + Expect(session.OutputToString()).To(ContainSubstring("search dns.podman")) + }) }) -- cgit v1.2.3-54-g00ecf