summaryrefslogtreecommitdiff
path: root/pkg/specgen/namespaces.go
diff options
context:
space:
mode:
authorGiuseppe Scrivano <gscrivan@redhat.com>2020-07-16 12:19:51 +0200
committerGiuseppe Scrivano <gscrivan@redhat.com>2020-07-16 22:37:27 +0200
commit9be7029cdd4736f3ac33004e4364e3e7f3bd1db5 (patch)
tree3471bf92af256dc4006f84a5f8fa4bcda090cdc2 /pkg/specgen/namespaces.go
parent8d12f19371eb9d91139f7b982cde2926ec8c8e74 (diff)
downloadpodman-9be7029cdd4736f3ac33004e4364e3e7f3bd1db5.tar.gz
podman-9be7029cdd4736f3ac33004e4364e3e7f3bd1db5.tar.bz2
podman-9be7029cdd4736f3ac33004e4364e3e7f3bd1db5.zip
libpod: pass down network options
do not pass network specific options through the network namespace. Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
Diffstat (limited to 'pkg/specgen/namespaces.go')
-rw-r--r--pkg/specgen/namespaces.go14
1 files changed, 0 insertions, 14 deletions
diff --git a/pkg/specgen/namespaces.go b/pkg/specgen/namespaces.go
index e62c8b709..9bf2c5d05 100644
--- a/pkg/specgen/namespaces.go
+++ b/pkg/specgen/namespaces.go
@@ -109,16 +109,6 @@ func validateNetNS(n *Namespace) error {
}
switch n.NSMode {
case Slirp:
- if n.Value != "" {
- parts := strings.Split(n.Value, ",")
- for _, p := range parts {
- switch p {
- case "port_handler=slirp4netns", "port_handler=rootlesskit":
- default:
- return errors.Errorf("invalid value for slirp %q", n.Value)
- }
- }
- }
break
case "", Default, Host, Path, FromContainer, FromPod, Private, NoNetwork, Bridge:
break
@@ -263,11 +253,7 @@ func ParseNetworkNamespace(ns string) (Namespace, []string, error) {
// Net defaults to Slirp on rootless
switch {
case ns == "slirp4netns", strings.HasPrefix(ns, "slirp4netns:"):
- split := strings.SplitN(ns, ":", 2)
toReturn.NSMode = Slirp
- if len(split) > 1 {
- toReturn.Value = split[1]
- }
case ns == "pod":
toReturn.NSMode = FromPod
case ns == "":