Skip to content

Commit

Permalink
tests: Fix unpriv test
Browse files Browse the repository at this point in the history
Don't use $TUSER as it's not defined. Also don't include
lxc-test-usernic in extra_DIST.

Signed-off-by: Stéphane Graber <stgraber@ubuntu.com>
  • Loading branch information
stgraber committed Nov 25, 2014
1 parent d9bae9c commit 8ac62e2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
1 change: 0 additions & 1 deletion src/tests/Makefile.am
Expand Up @@ -73,7 +73,6 @@ EXTRA_DIST = \
lxc-test-autostart \
lxc-test-ubuntu \
lxc-test-unpriv \
lxc-test-usernic \
may_control.c \
saveconfig.c \
shutdowntest.c \
Expand Down
6 changes: 3 additions & 3 deletions src/tests/lxc-test-usernic.in
Expand Up @@ -85,9 +85,9 @@ lxc.id_map = g 0 910000 10000
EOF

if which cgm >/dev/null 2>&1; then
cgm create all $TUSER
cgm chown all $TUSER $(id -u $TUSER) $(id -g $TUSER)
cgm movepid all $TUSER $$
cgm create all usernic-user
cgm chown all usernic-user $(id -u usernic-user) $(id -g usernic-user)
cgm movepid all usernic-user $$
elif [ -e /sys/fs/cgroup/cgmanager/sock ]; then
for d in $(cut -d : -f 2 /proc/self/cgroup); do
dbus-send --print-reply --address=unix:path=/sys/fs/cgroup/cgmanager/sock \
Expand Down

0 comments on commit 8ac62e2

Please sign in to comment.