diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2020-04-28 19:19:12 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-28 19:19:12 +0200 |
commit | 8f57f312d6c22b0c7c25f415872177f2ef9a0c7e (patch) | |
tree | eb38c62b41bb19d52a2ce42dcc648067d595440f | |
parent | 4ed125f7b5228b3e5898e23fbb91d6db8b9a6c18 (diff) | |
parent | e8e00133c1624a772434cd23d8e976a803b0cc15 (diff) | |
download | podman-8f57f312d6c22b0c7c25f415872177f2ef9a0c7e.tar.gz podman-8f57f312d6c22b0c7c25f415872177f2ef9a0c7e.tar.bz2 podman-8f57f312d6c22b0c7c25f415872177f2ef9a0c7e.zip |
Merge pull request #6020 from giuseppe/fix-exec
v2, podman: fix create tests
-rw-r--r-- | cmd/podman/common/specgen.go | 18 | ||||
-rw-r--r-- | cmd/podman/containers/exec.go | 2 | ||||
-rw-r--r-- | pkg/specgen/generate/container.go | 7 | ||||
-rw-r--r-- | test/e2e/exec_test.go | 1 |
4 files changed, 1 insertions, 27 deletions
diff --git a/cmd/podman/common/specgen.go b/cmd/podman/common/specgen.go index 5d5816ea4..f8c58f1a4 100644 --- a/cmd/podman/common/specgen.go +++ b/cmd/podman/common/specgen.go @@ -466,24 +466,6 @@ func FillOutSpecGen(s *specgen.SpecGenerator, c *ContainerCLIOpts, args []string s.CgroupParent = c.CGroupParent s.CgroupsMode = c.CGroupsMode s.Groups = c.GroupAdd - // TODO WTF - //cgroup := &cc.CgroupConfig{ - // Cgroupns: c.String("cgroupns"), - //} - // - //userns := &cc.UserConfig{ - // GroupAdd: c.StringSlice("group-add"), - // IDMappings: idmappings, - // UsernsMode: usernsMode, - // User: user, - //} - // - //uts := &cc.UtsConfig{ - // UtsMode: utsMode, - // NoHosts: c.Bool("no-hosts"), - // HostAdd: c.StringSlice("add-host"), - // Hostname: c.String("hostname"), - //} s.Hostname = c.Hostname sysctl := map[string]string{} diff --git a/cmd/podman/containers/exec.go b/cmd/podman/containers/exec.go index 3749c934a..2bff8ae33 100644 --- a/cmd/podman/containers/exec.go +++ b/cmd/podman/containers/exec.go @@ -70,7 +70,7 @@ func init() { registry.Commands = append(registry.Commands, registry.CliCommand{ Mode: []entities.EngineMode{entities.ABIMode}, Command: containerExecCommand, - Parent: containerCommitCommand, + Parent: containerCmd, }) containerExecFlags := containerExecCommand.Flags() diff --git a/pkg/specgen/generate/container.go b/pkg/specgen/generate/container.go index b27dd1cc2..75e8d8191 100644 --- a/pkg/specgen/generate/container.go +++ b/pkg/specgen/generate/container.go @@ -126,13 +126,6 @@ func CompleteSpec(ctx context.Context, r *libpod.Runtime, s *specgen.SpecGenerat if err != nil { return err } - - // TODO This should be enabled when namespaces actually work - //case usernsMode.IsKeepID(): - // user = fmt.Sprintf("%d:%d", rootless.GetRootlessUID(), rootless.GetRootlessGID()) - if len(s.User) == 0 { - s.User = "0" - } } if err := finishThrottleDevices(s); err != nil { return err diff --git a/test/e2e/exec_test.go b/test/e2e/exec_test.go index 3aac4b35b..8b95794d2 100644 --- a/test/e2e/exec_test.go +++ b/test/e2e/exec_test.go @@ -18,7 +18,6 @@ var _ = Describe("Podman exec", func() { ) BeforeEach(func() { - Skip(v2fail) tempdir, err = CreateTempDirInTempDir() if err != nil { os.Exit(1) |