Merge "Test nova server (VM) boot in overcloud job"
This commit is contained in:
commit
3037361cb0
@ -215,3 +215,24 @@ function overcloud_deploy {
|
|||||||
|
|
||||||
echo "Control plane deployment complete"
|
echo "Control plane deployment complete"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function overcloud_test {
|
||||||
|
# Perform a simple smoke test against the cloud.
|
||||||
|
echo "Performing a simple smoke test"
|
||||||
|
|
||||||
|
environment_setup
|
||||||
|
|
||||||
|
pip install python-openstackclient
|
||||||
|
|
||||||
|
echo "Running kolla-ansible init-runonce"
|
||||||
|
source "${KOLLA_CONFIG_PATH:-/etc/kolla}/admin-openrc.sh"
|
||||||
|
${KOLLA_VENV_PATH:-$HOME/kolla-venv}/share/kolla-ansible/init-runonce
|
||||||
|
|
||||||
|
echo "Creating a VM"
|
||||||
|
openstack server create --wait --image cirros --flavor m1.tiny --key-name mykey --network demo-net demo1
|
||||||
|
openstack server show demo1
|
||||||
|
# TODO(mgoddard): Test SSH connectivity to the VM.
|
||||||
|
|
||||||
|
echo "Deleting the VM"
|
||||||
|
openstack server delete --wait demo1
|
||||||
|
}
|
||||||
|
16
dev/overcloud-test.sh
Executable file
16
dev/overcloud-test.sh
Executable file
@ -0,0 +1,16 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
set -eu
|
||||||
|
set -o pipefail
|
||||||
|
|
||||||
|
PARENT="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||||
|
|
||||||
|
source "${PARENT}/functions"
|
||||||
|
|
||||||
|
|
||||||
|
function main {
|
||||||
|
config_init
|
||||||
|
overcloud_test
|
||||||
|
}
|
||||||
|
|
||||||
|
main
|
@ -8,3 +8,8 @@
|
|||||||
shell:
|
shell:
|
||||||
cmd: dev/overcloud-deploy.sh > {{ logs_dir }}/ansible/overcloud-deploy
|
cmd: dev/overcloud-deploy.sh > {{ logs_dir }}/ansible/overcloud-deploy
|
||||||
chdir: "{{ kayobe_src_dir }}"
|
chdir: "{{ kayobe_src_dir }}"
|
||||||
|
|
||||||
|
- name: Perform testing of the overcloud
|
||||||
|
shell:
|
||||||
|
cmd: dev/overcloud-test.sh > {{ logs_dir }}/ansible/overcloud-test
|
||||||
|
chdir: "{{ kayobe_src_dir }}"
|
||||||
|
Loading…
Reference in New Issue
Block a user