[lxc-devel] [PATCH 1/1] lxc-test-ubuntu: improve apparmor policy test

Serge Hallyn serge.hallyn at ubuntu.com
Fri Oct 18 15:43:24 UTC 2013


Also allow the standard non-nested apparmor policy.

Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
---
 src/tests/lxc-test-ubuntu | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/tests/lxc-test-ubuntu b/src/tests/lxc-test-ubuntu
index c6573c1..7fa1c89 100755
--- a/src/tests/lxc-test-ubuntu
+++ b/src/tests/lxc-test-ubuntu
@@ -68,7 +68,7 @@ for template in ubuntu ubuntu-cloud; do
 	# Check apparmor
 	lxcpid=`lxc-info -n $name -p | awk -F: '{ print $2 }' | awk '{ print $1}'`
 	aa=`cat /proc/$lxcpid/attr/current`
-	if [ "$aa" != "lxc-container-default-with-nesting (enforce)" ]; then
+	if [ "$aa" != "lxc-container-default-with-nesting (enforce)" -a "$aa" != "lxc-container-default (enforce)" ]; then
 		FAIL " to correctly set apparmor profile (profile is \"$aa\")"
 	fi
 	lxc-stop -n $name
-- 
1.8.3.2





More information about the lxc-devel mailing list