move nova-manage commands below the conf generation
This commit is contained in:
parent
25806832e2
commit
a074800ca8
27
stack.sh
27
stack.sh
@ -321,19 +321,6 @@ if [[ "$ENABLED_SERVICES" =~ "n-net" ]]; then
|
||||
mkdir -p $NOVA_DIR/networks
|
||||
fi
|
||||
|
||||
if [[ "$ENABLED_SERVICES" =~ "mysql" ]]; then
|
||||
# (re)create nova database
|
||||
mysql -u$MYSQL_USER -p$MYSQL_PASS -e 'DROP DATABASE nova;' || true
|
||||
mysql -u$MYSQL_USER -p$MYSQL_PASS -e 'CREATE DATABASE nova;'
|
||||
$NOVA_DIR/bin/nova-manage db sync
|
||||
|
||||
# create a small network
|
||||
$NOVA_DIR/bin/nova-manage network create private $FIXED_RANGE 1 32
|
||||
|
||||
# create some floating ips
|
||||
$NOVA_DIR/bin/nova-manage floating create $FLOATING_RANGE
|
||||
fi
|
||||
|
||||
function add_nova_flag {
|
||||
echo "$1" >> $NOVA_DIR/bin/nova.conf
|
||||
}
|
||||
@ -364,6 +351,20 @@ if [ -n "$MULTI_HOST" ]; then
|
||||
add_nova_flag "--multi_host=$MULTI_HOST"
|
||||
fi
|
||||
|
||||
if [[ "$ENABLED_SERVICES" =~ "mysql" ]]; then
|
||||
# (re)create nova database
|
||||
mysql -u$MYSQL_USER -p$MYSQL_PASS -e 'DROP DATABASE nova;' || true
|
||||
mysql -u$MYSQL_USER -p$MYSQL_PASS -e 'CREATE DATABASE nova;'
|
||||
$NOVA_DIR/bin/nova-manage db sync
|
||||
|
||||
# create a small network
|
||||
$NOVA_DIR/bin/nova-manage network create private $FIXED_RANGE 1 32
|
||||
|
||||
# create some floating ips
|
||||
$NOVA_DIR/bin/nova-manage floating create $FLOATING_RANGE
|
||||
fi
|
||||
|
||||
|
||||
# Keystone
|
||||
# --------
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user