summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--cmd/podman/shared/create.go3
-rw-r--r--docs/podman-container-runlabel.1.md2
-rw-r--r--test/e2e/run_dns_test.go7
3 files changed, 10 insertions, 2 deletions
diff --git a/cmd/podman/shared/create.go b/cmd/podman/shared/create.go
index 8e356cbcb..7dccc41f1 100644
--- a/cmd/podman/shared/create.go
+++ b/cmd/podman/shared/create.go
@@ -629,6 +629,9 @@ func ParseCreateOpts(ctx context.Context, c *GenericCLIResults, runtime *libpod.
// Validate domains are good
for _, dom := range c.StringSlice("dns-search") {
+ if dom == "." {
+ continue
+ }
if _, err := parse.ValidateDomain(dom); err != nil {
return nil, err
}
diff --git a/docs/podman-container-runlabel.1.md b/docs/podman-container-runlabel.1.md
index 9b74a3410..c16d8c3f4 100644
--- a/docs/podman-container-runlabel.1.md
+++ b/docs/podman-container-runlabel.1.md
@@ -20,8 +20,6 @@ If the container image has a LABEL INSTALL instruction like the following:
If the container image does not have the desired label, an error message will be displayed along with a non-zero
return code. If the image is not found in local storage, Podman will attempt to pull it first.
-Note: Podman will always ensure that `podman` is the first argument of the command being executed.
-
**LABEL**
The label name specified via the command.
diff --git a/test/e2e/run_dns_test.go b/test/e2e/run_dns_test.go
index 081fab3fd..dc0f4a8fb 100644
--- a/test/e2e/run_dns_test.go
+++ b/test/e2e/run_dns_test.go
@@ -41,6 +41,13 @@ var _ = Describe("Podman run dns", func() {
session.LineInOuputStartsWith("search foobar.com")
})
+ It("podman run remove all search domain", func() {
+ session := podmanTest.Podman([]string{"run", "--dns-search=.", ALPINE, "cat", "/etc/resolv.conf"})
+ session.WaitWithDefaultTimeout()
+ Expect(session.ExitCode()).To(Equal(0))
+ Expect(session.LineInOuputStartsWith("search")).To(BeFalse())
+ })
+
It("podman run add bad dns server", func() {
session := podmanTest.Podman([]string{"run", "--dns=foobar", ALPINE, "ls"})
session.WaitWithDefaultTimeout()