Merge pull request #444 from markdumay/partition

Support user namespaces in partition check (1.2.1)
This commit is contained in:
Thomas Sjögren 2020-09-29 11:24:17 +00:00 committed by GitHub
commit f3e9c791ce
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -73,8 +73,12 @@ check_1_2_1() {
starttestjson "$id_1_2_1" "$desc_1_2_1"
totalChecks=$((totalChecks + 1))
docker_root_dir=$(docker info -f '{{ .DockerRootDir }}')
if docker info | grep -q userns ; then
docker_root_dir=$(readlink -f "$docker_root_dir/..")
fi
if mountpoint -q -- "$(docker info -f '{{ .DockerRootDir }}')" >/dev/null 2>&1; then
if mountpoint -q -- "$docker_root_dir" >/dev/null 2>&1; then
pass "$check_1_2_1"
resulttestjson "PASS"
currentScore=$((currentScore + 1))