From: Stéphane Graber Date: Sun, 12 Apr 2020 03:05:04 +0000 (-0400) Subject: tests/no-new-privs: Don't mess with /etc/lxc X-Git-Tag: lxc-5.0.0~458^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F3374%2Fhead;p=thirdparty%2Flxc.git tests/no-new-privs: Don't mess with /etc/lxc Signed-off-by: Stéphane Graber --- diff --git a/src/tests/lxc-test-no-new-privs b/src/tests/lxc-test-no-new-privs index 8642992dd..cfcb43bd6 100755 --- a/src/tests/lxc-test-no-new-privs +++ b/src/tests/lxc-test-no-new-privs @@ -36,11 +36,13 @@ cleanup() { trap cleanup EXIT SIGHUP SIGINT SIGTERM -mkdir -p /etc/lxc/ -cat > /etc/lxc/default.conf << EOF +if [ ! -d /etc/lxc ]; then + mkdir -p /etc/lxc/ + cat > /etc/lxc/default.conf << EOF lxc.net.0.type = veth lxc.net.0.link = lxcbr0 EOF +fi ARCH=i386 if type dpkg >/dev/null 2>&1; then