From f9eeae6f4857a0c776caa516ffbd719c708cba2b Mon Sep 17 00:00:00 2001 From: Akihiro Suda Date: Mon, 2 Jul 2018 19:11:30 +0900 Subject: [PATCH] rootless: remove MapSubUIDGID flag that is ignored when already in userns Signed-off-by: Akihiro Suda --- executor/runcexecutor/executor.go | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/executor/runcexecutor/executor.go b/executor/runcexecutor/executor.go index f0dfc18da..97eb3430a 100644 --- a/executor/runcexecutor/executor.go +++ b/executor/runcexecutor/executor.go @@ -170,9 +170,7 @@ func (w *runcExecutor) Exec(ctx context.Context, meta executor.Meta, root cache. } if w.rootless { - specconv.ToRootless(spec, &specconv.RootlessOpts{ - MapSubUIDGID: true, - }) + specconv.ToRootless(spec, nil) // TODO(AkihiroSuda): keep Cgroups enabled if /sys/fs/cgroup/cpuset/buildkit exists and writable spec.Linux.CgroupsPath = "" // TODO(AkihiroSuda): ToRootless removes netns, but we should readd netns here