Special casing for Ironic VIRT_DRIVER in exercises

Ironic on Devstack does not currently suppport security groups or
anything volume related.  Add some special casing so exercises can
be run without error against the Ironic driver.

Change-Id: I2a54d8cca06fc17894e74b4401af9423cef95635
This commit is contained in:
Adam Gandelman 2014-03-17 19:47:14 -07:00
parent 911cc586ad
commit b875d01cdf
4 changed files with 11 additions and 2 deletions

View File

@ -44,6 +44,9 @@ source $TOP_DIR/exerciserc
# the exercise is skipped
is_service_enabled cinder || exit 55
# Ironic does not support boot from volume.
[ "$VIRT_DRIVER" == "ironic" ] && exit 55
# Instance type to create
DEFAULT_INSTANCE_TYPE=${DEFAULT_INSTANCE_TYPE:-m1.tiny}

View File

@ -36,6 +36,9 @@ source $TOP_DIR/eucarc
# Import exercise configuration
source $TOP_DIR/exerciserc
# Import project functions
source $TOP_DIR/lib/neutron
# If nova api is not enabled we exit with exitcode 55 so that
# the exercise is skipped
is_service_enabled n-api || exit 55
@ -82,7 +85,7 @@ fi
# Volumes
# -------
if is_service_enabled c-vol && ! is_service_enabled n-cell; then
if is_service_enabled c-vol && ! is_service_enabled n-cell && [ "$VIRT_DRIVER" != "ironic" ]; then
VOLUME_ZONE=`euca-describe-availability-zones | head -n1 | cut -f2`
die_if_not_set $LINENO VOLUME_ZONE "Failure to find zone for volume"

View File

@ -180,7 +180,7 @@ if ! timeout $ASSOCIATE_TIMEOUT sh -c "while nova secgroup-list-rules $SECGROUP
fi
# FIXME (anthony): make xs support security groups
if [ "$VIRT_DRIVER" != "xenserver" -a "$VIRT_DRIVER" != "openvz" ]; then
if [ "$VIRT_DRIVER" != "ironic" -a "$VIRT_DRIVER" != "xenserver" -a "$VIRT_DRIVER" != "openvz" ]; then
# Test we can aren't able to ping our floating ip within ASSOCIATE_TIMEOUT seconds
ping_check "$PUBLIC_NETWORK_NAME" $FLOATING_IP $ASSOCIATE_TIMEOUT Fail
fi

View File

@ -41,6 +41,9 @@ source $TOP_DIR/exerciserc
# exercise is skipped.
is_service_enabled cinder || exit 55
# Ironic does not currently support volume attachment.
[ "$VIRT_DRIVER" == "ironic" ] && exit 55
# Instance type to create
DEFAULT_INSTANCE_TYPE=${DEFAULT_INSTANCE_TYPE:-m1.tiny}