summaryrefslogtreecommitdiff
path: root/test/kpod_run.bats
diff options
context:
space:
mode:
authorDaniel J Walsh <dwalsh@redhat.com>2017-11-05 17:06:25 -0500
committerGitHub <noreply@github.com>2017-11-05 17:06:25 -0500
commitdbd524e3d18fbfc422ded06571b95c3513be9771 (patch)
tree584b740d106bbc43e9d614711ea0eddd0a263cd6 /test/kpod_run.bats
parentb06190e0da66f45cbe6a44d79065fabcd00ea19c (diff)
parent619637a9197877f3bda54648f9fabc4af90cf9c2 (diff)
downloadpodman-dbd524e3d18fbfc422ded06571b95c3513be9771.tar.gz
podman-dbd524e3d18fbfc422ded06571b95c3513be9771.tar.bz2
podman-dbd524e3d18fbfc422ded06571b95c3513be9771.zip
Merge pull request #17 from rhatdan/caps
Add support for Caps Options.
Diffstat (limited to 'test/kpod_run.bats')
-rw-r--r--test/kpod_run.bats20
1 files changed, 20 insertions, 0 deletions
diff --git a/test/kpod_run.bats b/test/kpod_run.bats
index d0cac96de..20b3a2dfe 100644
--- a/test/kpod_run.bats
+++ b/test/kpod_run.bats
@@ -36,3 +36,23 @@ ALPINE="docker.io/library/alpine:latest"
[ "$status" -eq 0 ]
}
+
+@test "run selinux test" {
+
+ run ${KPOD_BINARY} ${KPOD_OPTIONS} run --cap-add all ${ALPINE} cat /proc/self/status
+ echo "$output"
+ [ "$status" -eq 0 ]
+
+ run ${KPOD_BINARY} ${KPOD_OPTIONS} run --cap-add sys_admin ${ALPINE} cat /proc/self/status
+ echo "$output"
+ [ "$status" -eq 0 ]
+
+ run ${KPOD_BINARY} ${KPOD_OPTIONS} run --cap-drop all ${ALPINE} cat /proc/self/status
+ echo "$output"
+ [ "$status" -eq 0 ]
+
+ run ${KPOD_BINARY} ${KPOD_OPTIONS} run --cap-drop setuid ${ALPINE} cat /proc/self/status
+ echo "$output"
+ [ "$status" -eq 0 ]
+
+}