diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2021-11-12 19:59:44 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-11-12 19:59:44 +0100 |
commit | 78bc2390f4d03ef4b179b129c69b5332c30692ce (patch) | |
tree | c85bd4dc36ca99f2f923e28000477c51547ac693 /pkg/specgen/generate | |
parent | 0aecacb8655d65cb55ec09a9629a358236e6af73 (diff) | |
parent | 164c42b4857c63fa9750599a9242709ed18c57db (diff) | |
download | podman-78bc2390f4d03ef4b179b129c69b5332c30692ce.tar.gz podman-78bc2390f4d03ef4b179b129c69b5332c30692ce.tar.bz2 podman-78bc2390f4d03ef4b179b129c69b5332c30692ce.zip |
Merge pull request #12271 from Luap99/play-kube-net
Fix network mode in play kube
Diffstat (limited to 'pkg/specgen/generate')
-rw-r--r-- | pkg/specgen/generate/pod_create.go | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/pkg/specgen/generate/pod_create.go b/pkg/specgen/generate/pod_create.go index 501bce05d..bfd81739a 100644 --- a/pkg/specgen/generate/pod_create.go +++ b/pkg/specgen/generate/pod_create.go @@ -12,7 +12,6 @@ import ( "github.com/containers/podman/v3/libpod" "github.com/containers/podman/v3/libpod/define" "github.com/containers/podman/v3/pkg/domain/entities" - "github.com/containers/podman/v3/pkg/rootless" "github.com/containers/podman/v3/pkg/specgen" "github.com/pkg/errors" "github.com/sirupsen/logrus" @@ -216,15 +215,6 @@ func MapSpec(p *specgen.PodSpecGenerator) (*specgen.SpecGenerator, error) { logrus.Debugf("No networking because the infra container is missing") break } - if rootless.IsRootless() { - logrus.Debugf("Pod will use slirp4netns") - if p.InfraContainerSpec.NetNS.NSMode != "host" { - p.InfraContainerSpec.NetworkOptions = p.NetworkOptions - p.InfraContainerSpec.NetNS.NSMode = specgen.NamespaceMode("slirp4netns") - } - } else { - logrus.Debugf("Pod using bridge network mode") - } case specgen.Bridge: p.InfraContainerSpec.NetNS.NSMode = specgen.Bridge logrus.Debugf("Pod using bridge network mode") @@ -258,7 +248,6 @@ func MapSpec(p *specgen.PodSpecGenerator) (*specgen.SpecGenerator, error) { return nil, errors.Errorf("pods presently do not support network mode %s", p.NetNS.NSMode) } - libpod.WithPodCgroups() if len(p.InfraCommand) > 0 { p.InfraContainerSpec.Entrypoint = p.InfraCommand } |