# TODO: This should maybe go into openrc instead!?
export OS_IMAGE_API_VERSION=1
+ # Install required packages.
+ # 'qemu-nbd' is needed when building the yardstick image.
+ sudo yum -y install qemu-img
+
# set virtualenv
echo "Yardstick: setup virtualenv"
cd $WORKSPACE
IMAGE_NAMES[1]=yardstick-trusty-server
if ! nova image-show ${IMAGE_NAMES[1]} > /dev/null 2>&1; then
echo "Image ${IMAGE_NAMES[1]} doesn't exist. Creating image ${IMAGE_NAMES[1]}"
- sudo yardstick-img-modify $WORKSPACE/tools/ubuntu-server-cloudimg-modify.sh
+ sudo $(which yardstick-img-modify) $WORKSPACE/tools/ubuntu-server-cloudimg-modify.sh
glance image-create --name yardstick-trusty-server --is-public true --disk-format qcow2 --container-format bare --file $WORKSPACE/yardstick-trusty-server.img
fi