more work on multi-lxc
diff --git a/build_lxc.sh b/build_lxc.sh
index 9f133fd..4987193 100755
--- a/build_lxc.sh
+++ b/build_lxc.sh
@@ -120,13 +120,16 @@
echo "nameserver $NAMESERVER" | resolvconf -a eth0
sleep 1
+# Kill any existing screens
+sudo -c "killall screen" stack
+
# Install and run stack.sh
apt-get update
apt-get -y --force-yes install git-core vim-nox sudo
if [ ! -d "/opt/nfs-stack" ]; then
su -c "git clone git://github.com/cloudbuilders/nfs-stack.git ~/nfs-stack" stack
fi
-nohup su -c "cd ~/nfs-stack && $STACKSH_PARAMS ./stack.sh" stack &> /opt/run.sh.log
+su -c "cd ~/nfs-stack && $STACKSH_PARAMS ./stack.sh" stack &> /opt/run.sh.log
EOF
# Make the run.sh executable
diff --git a/stack.sh b/stack.sh
index 62f813a..88e779c 100755
--- a/stack.sh
+++ b/stack.sh
@@ -37,7 +37,7 @@
NOVNC_DIR=$DEST/noVNC
# Specify which services to launch. These generally correspond to screen tabs
-ENABLED_SERVICES=g-api,g-reg,key,n-api,n-cpu,n-net,n-sch,n-vnc,dash
+ENABLED_SERVICES=${ENABLED_SERVICES:-g-api,g-reg,key,n-api,n-cpu,n-net,n-sch,n-vnc,dash}
# Use the first IP unless an explicit is set by ``HOST_IP`` environment variable
if [ ! -n "$HOST_IP" ]; then