summaryrefslogtreecommitdiff
path: root/libpod/container_internal.go
diff options
context:
space:
mode:
authorGiuseppe Scrivano <gscrivan@redhat.com>2018-07-25 15:15:13 +0200
committerAtomic Bot <atomic-devel@projectatomic.io>2018-07-31 13:39:29 +0000
commitcfcd92847684fc65949350b7cdc4769ad1099d46 (patch)
treeafb9f946fb54fc990d83b9814b77e522b9bd4221 /libpod/container_internal.go
parent5b9c60cc10f7dec6d0b030ad16646728f30a67e9 (diff)
downloadpodman-cfcd92847684fc65949350b7cdc4769ad1099d46.tar.gz
podman-cfcd92847684fc65949350b7cdc4769ad1099d46.tar.bz2
podman-cfcd92847684fc65949350b7cdc4769ad1099d46.zip
network: add support for rootless network with slirp4netns
slirp4netns is required to setup the network namespace: https://github.com/rootless-containers/slirp4netns Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com> Closes: #1156 Approved by: rhatdan
Diffstat (limited to 'libpod/container_internal.go')
-rw-r--r--libpod/container_internal.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/libpod/container_internal.go b/libpod/container_internal.go
index 8a96af0ab..2f258d007 100644
--- a/libpod/container_internal.go
+++ b/libpod/container_internal.go
@@ -524,12 +524,12 @@ func (c *Container) completeNetworkSetup() error {
if !c.config.PostConfigureNetNS {
return nil
}
- if rootless.IsRootless() {
- return nil
- }
if err := c.syncContainer(); err != nil {
return err
}
+ if rootless.IsRootless() {
+ return c.runtime.setupRootlessNetNS(c)
+ }
return c.runtime.setupNetNS(c)
}