Support to test non-dev guest image in CI

Make the job non-voting because it may fail when the guest agent code
changes.

Change-Id: Ibd595b5b5c02cf72f1e5f05c79469cd4cb15a3ca
This commit is contained in:
Lingxian Kong 2020-03-12 11:33:50 +13:00
parent 7d78c74158
commit c952838a9b
3 changed files with 34 additions and 10 deletions

View File

@ -27,6 +27,8 @@
voting: false
- trove-tempest-ipv6-only:
voting: false
- trove-functional-mysql-nondev:
voting: false
gate:
queue: trove
jobs:
@ -144,6 +146,18 @@
trove_test_group: 'mysql'
trove_test_datastore_version: '5.7'
- job:
name: trove-functional-mysql-nondev
parent: trove-devstack-base
vars:
devstack_localrc:
TROVE_RESIZE_TIME_OUT: 1800
TROVE_NON_DEV_IMAGE_URL_MYSQL: https://tarballs.opendev.org/openstack/trove/images/trove-master-mysql-ubuntu-xenial.qcow2
trove_resize_time_out: 1800
trove_test_datastore: 'mysql'
trove_test_group: 'mysql'
trove_test_datastore_version: '5.7'
- job:
name: trove-grenade
parent: trove-legacy-dsvm-base

View File

@ -447,20 +447,29 @@ function create_guest_image {
return 0
fi
echo "Starting to create guest image..."
TROVE_BRANCH=${TROVE_BRANCH} $DEST/trove/integration/scripts/trovestack \
build-image \
${TROVE_DATASTORE_TYPE} \
${TROVE_IMAGE_OS} \
${TROVE_IMAGE_OS_RELEASE} \
true
image_name="trove-datastore-${TROVE_IMAGE_OS}-${TROVE_IMAGE_OS_RELEASE}-${TROVE_DATASTORE_TYPE}"
image_url_var="TROVE_NON_DEV_IMAGE_URL_${TROVE_DATASTORE_TYPE^^}"
image_url=`eval echo '$'"$image_url_var"`
mkdir -p $HOME/images
image_file=$HOME/images/${image_name}.qcow2
if [[ -n ${image_url} ]]; then
echo "Downloading guest image from ${image_url}"
curl -sSL ${image_url} -o ${image_file}
else
echo "Starting to create guest image"
TROVE_BRANCH=${TROVE_BRANCH} $DEST/trove/integration/scripts/trovestack \
build-image \
${TROVE_DATASTORE_TYPE} \
${TROVE_IMAGE_OS} \
${TROVE_IMAGE_OS_RELEASE} \
true
fi
if [ ! -f ${image_file} ]; then
echo "Image file was not found at ${image_file}"
return 1
exit 1
fi
echo "Add the image to glance"

View File

@ -90,3 +90,4 @@ CELLSV2_SETUP=singleconductor
# Enable or disable the Trove guest image build during devstack installation.
TROVE_ENABLE_IMAGE_BUILD=${TROVE_ENABLE_IMAGE_BUILD:-"true"}
TROVE_NON_DEV_IMAGE_URL_MYSQL=${TROVE_NON_DEV_IMAGE_URL_MYSQL:-""}