summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2019-07-24 12:47:29 +0200
committerGitHub <noreply@github.com>2019-07-24 12:47:29 +0200
commit0d441f57d64bcca16c14ca44b7c8f35ab687ea3f (patch)
tree1c5f87a8c2e37be4a23277395afa6720edd4ecfc
parent0e85b82741a653b8bb6ce7a54301d5ffd3c70f5d (diff)
parent8c9b78e8bcb200220f2871c4c9b43d69f6939a38 (diff)
downloadpodman-0d441f57d64bcca16c14ca44b7c8f35ab687ea3f.tar.gz
podman-0d441f57d64bcca16c14ca44b7c8f35ab687ea3f.tar.bz2
podman-0d441f57d64bcca16c14ca44b7c8f35ab687ea3f.zip
Merge pull request #3633 from QiWang19/network
fix build --network=container
-rw-r--r--cmd/podman/build.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/cmd/podman/build.go b/cmd/podman/build.go
index 19337985d..14ac51889 100644
--- a/cmd/podman/build.go
+++ b/cmd/podman/build.go
@@ -101,6 +101,10 @@ func getNsValues(c *cliconfig.BuildValues) ([]buildah.NamespaceOption, error) {
Name: string(specs.NetworkNamespace),
Host: true,
})
+ } else if c.Network == "container" {
+ ret = append(ret, buildah.NamespaceOption{
+ Name: string(specs.NetworkNamespace),
+ })
} else if c.Network[0] == '/' {
ret = append(ret, buildah.NamespaceOption{
Name: string(specs.NetworkNamespace),