summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorGiuseppe Scrivano <gscrivan@redhat.com>2019-07-18 11:38:54 +0200
committerGiuseppe Scrivano <gscrivan@redhat.com>2019-07-18 17:07:50 +0200
commit350ede1eeb6ab33bce2918d7768b940c255e63c6 (patch)
treeba65d688c51ce2374e349bf874751404e13e0309 /test
parent7488ed6d9a619d86333dc1880d4df034fbb371b9 (diff)
downloadpodman-350ede1eeb6ab33bce2918d7768b940c255e63c6.tar.gz
podman-350ede1eeb6ab33bce2918d7768b940c255e63c6.tar.bz2
podman-350ede1eeb6ab33bce2918d7768b940c255e63c6.zip
rootless: add rw devices with --privileged
when --privileged is specified, add all the devices that are usable by the user. Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1730773 Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
Diffstat (limited to 'test')
-rw-r--r--test/e2e/run_device_test.go9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/e2e/run_device_test.go b/test/e2e/run_device_test.go
index 2e537a9f9..cf7ce9cdf 100644
--- a/test/e2e/run_device_test.go
+++ b/test/e2e/run_device_test.go
@@ -85,4 +85,13 @@ var _ = Describe("Podman run device", func() {
session.WaitWithDefaultTimeout()
Expect(session.ExitCode()).To(Equal(0))
})
+
+ It("podman run device host device with --privileged", func() {
+ if _, err := os.Stat("/dev/kvm"); err != nil {
+ Skip("/dev/kvm not available")
+ }
+ session := podmanTest.Podman([]string{"run", "--privileged", ALPINE, "ls", "/dev/kvm"})
+ session.WaitWithDefaultTimeout()
+ Expect(session.ExitCode()).To(Equal(0))
+ })
})