diff options
author | Paul Holzinger <pholzing@redhat.com> | 2022-04-19 13:58:35 +0200 |
---|---|---|
committer | Paul Holzinger <pholzing@redhat.com> | 2022-04-22 12:59:49 +0200 |
commit | 696bcd2773cf6c255855db9cf2ef724547626438 (patch) | |
tree | 5e2256d4a006c152b12a14f1067b8949f250d656 /test/e2e | |
parent | 1fcefc94f9e3e6d9dedeccc83fa3964461519b7f (diff) | |
download | podman-696bcd2773cf6c255855db9cf2ef724547626438.tar.gz podman-696bcd2773cf6c255855db9cf2ef724547626438.tar.bz2 podman-696bcd2773cf6c255855db9cf2ef724547626438.zip |
use etchosts package from c/common
Use the new logic from c/common to create the hosts file. This will help
to better allign the hosts files between buildah and podman.
Also this fixes several bugs:
- remove host entries when container is stopped and has a netNsCtr
- add entries for containers in a pod
- do not duplicate entries in the hosts file
- use the correct slirp ip when an userns is used
Features:
- configure host.containers.internal entry in containers.conf
- configure base hosts file in containers.conf
Fixes #12003
Fixes #13224
Signed-off-by: Paul Holzinger <pholzing@redhat.com>
Diffstat (limited to 'test/e2e')
-rw-r--r-- | test/e2e/run_dns_test.go | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/test/e2e/run_dns_test.go b/test/e2e/run_dns_test.go index a313e8d40..7561a2e85 100644 --- a/test/e2e/run_dns_test.go +++ b/test/e2e/run_dns_test.go @@ -78,8 +78,7 @@ var _ = Describe("Podman run dns", func() { session := podmanTest.Podman([]string{"run", "--add-host=foobar:1.1.1.1", "--add-host=foobaz:2001:db8::68", ALPINE, "cat", "/etc/hosts"}) session.WaitWithDefaultTimeout() Expect(session).Should(Exit(0)) - Expect(session.OutputToStringArray()).To(ContainElement(HavePrefix("1.1.1.1 foobar"))) - Expect(session.OutputToStringArray()).To(ContainElement(HavePrefix("2001:db8::68 foobaz"))) + Expect(session.OutputToStringArray()).To(ContainElements(HavePrefix("1.1.1.1\tfoobar"), HavePrefix("2001:db8::68\tfoobaz"))) }) It("podman run add hostname", func() { |