mirror of
https://github.com/containers/podman.git
synced 2025-12-19 07:09:39 +08:00
Don't ignore --user flag in rootless --userns keepid
Currently podman run --userns keep-id --user root:root fedora id The --user flag is ignored. Removing this makes the code work correctly. Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
This commit is contained in:
@@ -89,6 +89,13 @@ var _ = Describe("Podman UserNS support", func() {
|
||||
Expect(ok).To(BeTrue())
|
||||
})
|
||||
|
||||
It("podman --userns=keep-id --user root:root", func() {
|
||||
session := podmanTest.Podman([]string{"run", "--userns=keep-id", "--user", "root:root", "alpine", "id", "-u"})
|
||||
session.WaitWithDefaultTimeout()
|
||||
Expect(session.ExitCode()).To(Equal(0))
|
||||
Expect(session.OutputToString()).To(Equal("0"))
|
||||
})
|
||||
|
||||
It("podman --userns=auto", func() {
|
||||
u, err := user.Current()
|
||||
Expect(err).To(BeNil())
|
||||
|
||||
Reference in New Issue
Block a user