summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGiuseppe Scrivano <gscrivan@redhat.com>2018-08-16 17:31:09 +0200
committerAtomic Bot <atomic-devel@projectatomic.io>2018-08-16 16:02:32 +0000
commitc0abfaa7c38a8fc897a4c1f64392ace40a5a10c1 (patch)
tree658ed7351357b9b5cf88d817a5518c4928f32bcd
parent1003df344424dc3b2bb7f957818359105dbfe4be (diff)
downloadpodman-c0abfaa7c38a8fc897a4c1f64392ace40a5a10c1.tar.gz
podman-c0abfaa7c38a8fc897a4c1f64392ace40a5a10c1.tar.bz2
podman-c0abfaa7c38a8fc897a4c1f64392ace40a5a10c1.zip
Revert "spec: bind mount /sys only for rootless containers"
It breaks "podman run --net=host --uidmap=0:1:70000 --gidmap=0:20000:70000 busybox echo hi" Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com> Closes: #1285 Approved by: rhatdan
-rw-r--r--pkg/spec/spec.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/pkg/spec/spec.go b/pkg/spec/spec.go
index 231cb59fc..bceae4677 100644
--- a/pkg/spec/spec.go
+++ b/pkg/spec/spec.go
@@ -35,7 +35,7 @@ func CreateConfigToOCISpec(config *CreateConfig) (*spec.Spec, error) { //nolint
Options: []string{"nosuid", "noexec", "nodev", "rw"},
}
g.AddMount(sysMnt)
- } else if rootless.IsRootless() && !config.UsernsMode.IsHost() && config.NetMode.IsHost() {
+ } else if !config.UsernsMode.IsHost() && config.NetMode.IsHost() {
addCgroup = false
g.RemoveMount("/sys")
sysMnt := spec.Mount{