xci: Adjust and fix jobs and scripts
[releng.git] / prototypes / bifrost / scripts / bifrost-provision.sh
index 0c13a84..d3b28ee 100755 (executable)
@@ -14,6 +14,7 @@ export PYTHONUNBUFFERED=1
 SCRIPT_HOME="$(cd "$(dirname "$0")" && pwd)"
 BIFROST_HOME=$SCRIPT_HOME/..
 ANSIBLE_INSTALL_ROOT=${ANSIBLE_INSTALL_ROOT:-/opt/stack}
+ANSIBLE_VERBOSITY=${ANSIBLE_VERBOSITY-"-vvvv"}
 ENABLE_VENV="false"
 USE_DHCP="false"
 USE_VENV="false"
@@ -33,7 +34,7 @@ export BIFROST_INVENTORY_SOURCE=$BAREMETAL_DATA_FILE
 
 # Default settings for VMs
 export TEST_VM_NUM_NODES=${TEST_VM_NUM_NODES:-3}
-export TEST_VM_NODE_NAMES=${TEST_VM_NODE_NAMES:-"xcimaster controller00 compute00"}
+export TEST_VM_NODE_NAMES=${TEST_VM_NODE_NAMES:-"opnfv controller00 compute00"}
 export VM_DOMAIN_TYPE=${VM_DOMAIN_TYPE:-kvm}
 export VM_CPU=${VM_CPU:-4}
 export VM_DISK=${VM_DISK:-100}
@@ -83,19 +84,19 @@ cd $BIFROST_HOME/playbooks
 
 # Syntax check of dynamic inventory test path
 for task in syntax-check list-tasks; do
-    ${ANSIBLE} -vvvv \
+    ${ANSIBLE} ${ANSIBLE_VERBOSITY} \
            -i inventory/localhost \
            test-bifrost-create-vm.yaml \
            --${task}
-    ${ANSIBLE} -vvvv \
+    ${ANSIBLE} ${ANSIBLE_VERBOSITY} \
            -i inventory/localhost \
            ${TEST_PLAYBOOK} \
            --${task} \
            -e testing_user=${TESTING_USER}
 done
 
-# Create the test VMS
-${ANSIBLE} -vvvv \
+# Create the VMS
+${ANSIBLE} ${ANSIBLE_VERBOSITY} \
        -i inventory/localhost \
        test-bifrost-create-vm.yaml \
        -e test_vm_num_nodes=${TEST_VM_NUM_NODES} \
@@ -104,8 +105,8 @@ ${ANSIBLE} -vvvv \
        -e test_vm_domain_type=${VM_DOMAIN_TYPE} \
        -e ${INVENTORY_FILE_FORMAT}=${BAREMETAL_DATA_FILE}
 
-# Execute the installation and VM startup test.
-${ANSIBLE} -vvvv \
+# Execute the installation and VM startup test
+${ANSIBLE} ${ANSIBLE_VERBOSITY} \
     -i inventory/bifrost_inventory.py \
     ${TEST_PLAYBOOK} \
     -e use_cirros=${USE_CIRROS} \