performance: use local disk if one exists labeled nova-instances
diff --git a/stack.sh b/stack.sh
index 2d32f1e..78d9b4d 100755
--- a/stack.sh
+++ b/stack.sh
@@ -176,9 +176,13 @@
screen -d -m -S nova -t nova
sleep 1
rm -f $NOVA_DIR/nova.sqlite
- # TODO(ja): mount local partition nova-instances (can we use labels?)
- rm -rf $NOVA_DIR/instances
+ rm -rf $NOVA_DIR/instances/*
mkdir -p $NOVA_DIR/instances
+ # if there is a partition labeled nova-instances use it (ext filesystems
+ # can be labeled via e2label)
+ if [ -L /dev/disk/by-label/nova-instances ]; then
+ mount -L nova-instances /$NOVA_DIR/instances
+ fi
rm -rf $NOVA_DIR/networks
mkdir -p $NOVA_DIR/networks