[lxc-devel] [lxc/master] tests: Support systemd hybrid cgroups
stgraber on Github
lxc-bot at linuxcontainers.org
Mon Sep 18 22:19:29 UTC 2017
A non-text attachment was scrubbed...
Name: not available
Type: text/x-mailbox
Size: 354 bytes
Desc: not available
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20170918/342567ac/attachment.bin>
-------------- next part --------------
From 8d5a91fc6580876c503a44879c3f54dbc61e8a73 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?St=C3=A9phane=20Graber?= <stgraber at ubuntu.com>
Date: Fri, 12 May 2017 12:28:20 -0400
Subject: [PATCH] tests: Support systemd hybrid cgroups
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
---
src/tests/lxc-test-apparmor-mount | 1 +
src/tests/lxc-test-unpriv | 1 +
src/tests/lxc-test-usernic.in | 1 +
3 files changed, 3 insertions(+)
diff --git a/src/tests/lxc-test-apparmor-mount b/src/tests/lxc-test-apparmor-mount
index a09fd5443..ddcee8a76 100755
--- a/src/tests/lxc-test-apparmor-mount
+++ b/src/tests/lxc-test-apparmor-mount
@@ -132,6 +132,7 @@ elif [ -e /sys/fs/cgroup/cgmanager/sock ]; then
done
else
for d in /sys/fs/cgroup/*; do
+ [ "$d" = "/sys/fs/cgroup/unified" ] && continue
[ -f $d/cgroup.clone_children ] && echo 1 > $d/cgroup.clone_children
[ ! -d $d/lxctest ] && mkdir $d/lxctest
chown -R $TUSER: $d/lxctest
diff --git a/src/tests/lxc-test-unpriv b/src/tests/lxc-test-unpriv
index 5fe092794..5f2a18f68 100755
--- a/src/tests/lxc-test-unpriv
+++ b/src/tests/lxc-test-unpriv
@@ -148,6 +148,7 @@ elif [ -e /sys/fs/cgroup/cgmanager/sock ]; then
done
else
for d in /sys/fs/cgroup/*; do
+ [ "$d" = "/sys/fs/cgroup/unified" ] && continue
[ -f $d/cgroup.clone_children ] && echo 1 > $d/cgroup.clone_children
[ ! -d $d/lxctest ] && mkdir $d/lxctest
chown -R $TUSER: $d/lxctest
diff --git a/src/tests/lxc-test-usernic.in b/src/tests/lxc-test-usernic.in
index f7d19a362..3e35008c6 100755
--- a/src/tests/lxc-test-usernic.in
+++ b/src/tests/lxc-test-usernic.in
@@ -105,6 +105,7 @@ elif [ -e /sys/fs/cgroup/cgmanager/sock ]; then
done
else
for d in /sys/fs/cgroup/*; do
+ [ "$d" = "/sys/fs/cgroup/unified" ] && continue
[ -f $d/cgroup.clone_children ] && echo 1 > $d/cgroup.clone_children
[ ! -d $d/lxctest ] && mkdir $d/lxctest
chown -R usernic-user: $d/lxctest
More information about the lxc-devel
mailing list