Reported-by: Michael J. Evans
Signed-off-by: Stéphane Graber <stgraber@ubuntu.com>
# Only run on a normally configured ubuntu lxc system
if [ ! -d /sys/class/net/lxcbr0 ]; then
echo "lxcbr0 is not configured."
- exit 0
+ exit 1
fi
if [ "$(id -u)" != "0" ]; then
- echo "Must run as root."
- exit 0
+ echo "ERROR: Must run as root."
+ exit 1
fi
if ! which host 2>&1 > /dev/null; then
echo "'host' program not found. Please install bind9-host"
- exit 0
+ exit 1
fi
for template in ubuntu ubuntu-cloud; do
# This test assumes an Ubuntu host
if [ $(id -u) -ne 0 ]; then
- echo 'run as root'
+ echo "ERROR: Must run as root."
exit 1
fi
which newuidmap >/dev/null 2>&1 || { echo "'newuidmap' command is missing" >&2; exit 1; }