Create the default storage pool before calling create-node.sh

create-node.sh no longer does this (in devstack its done in
devstack/lib/ironic).

Change-Id: I26d440adfc9e3e75d120c1a644f82784d6cf31da
This commit is contained in:
Derek Higgins 2019-11-21 13:36:05 +00:00
parent d2bcf0f530
commit 189341fde3
2 changed files with 17 additions and 0 deletions

View File

@ -44,6 +44,22 @@ resources:
docker restart neutron_api
LIBVIRT_STORAGE_POOL=${LIBVIRT_STORAGE_POOL:-"default"}
LIBVIRT_STORAGE_POOL_PATH=${LIBVIRT_STORAGE_POOL_PATH:-/var/lib/libvirt/images}
mkdir -p $LIBVIRT_STORAGE_POOL_PATH
if ! virsh pool-list --all | grep -q $LIBVIRT_STORAGE_POOL; then
virsh pool-define-as --name $LIBVIRT_STORAGE_POOL dir --target $LIBVIRT_STORAGE_POOL_PATH
virsh pool-autostart $LIBVIRT_STORAGE_POOL
virsh pool-start $LIBVIRT_STORAGE_POOL
fi
pool_state=$(virsh pool-info $LIBVIRT_STORAGE_POOL | grep State | awk '{ print $2 }')
if [ "$pool_state" != "running" ] ; then
virsh pool-start $LIBVIRT_STORAGE_POOL
fi
# nohup needed as vbmc seems to keep stdin open
nohup /tmp/ironic/devstack/tools/ironic/scripts/create-node.sh -n node1 -c 1 -m 3072 -d 10 -b br-ex -p 1161 -M 1350 -f qcow2 -a x86_64 -E qemu -e /usr/bin/qemu-system-x86_64 -l /var/log/bmlogs -A 66:0d:1d:d8:0b:11 > ~zuul/create-node-1.log 2>&1 < /dev/null
nohup /tmp/ironic/devstack/tools/ironic/scripts/create-node.sh -n node2 -c 1 -m 3072 -d 10 -b br-ex -p 1162 -M 1350 -f qcow2 -a x86_64 -E qemu -e /usr/bin/qemu-system-x86_64 -l /var/log/bmlogs -A 66:0d:1d:d8:0b:22 > ~zuul/create-node-2.log 2>&1 < /dev/null &

View File

@ -1,3 +1,4 @@
# touching file so CI runs scenario012
resource_registry:
OS::TripleO::Controller::Net::SoftwareConfig: ../common/net-config-multinode.yaml
OS::TripleO::Compute::Net::SoftwareConfig: ../common/net-config-multinode.yaml