Glance v1 is deprecated and removed in devstack [1]

With this patch we will use glance v2 api's for interacting
with glance.

[1] I7f962a07317cdad917ee896d79e49ee18938d074

Closes-Bug: 1672535

Change-Id: Iedc25b55ad2751e14d3794b1cb80f724f1a735c4
This commit is contained in:
trilliams 2017-03-13 19:00:22 -05:00 committed by yatinkarel
parent dd2a8520cb
commit 3a9e8cfb40
2 changed files with 2 additions and 4 deletions

View File

@ -280,7 +280,7 @@ function magnum_register_image {
echo "Unknown image extension in $image_filename, supported extensions: tgz, img, qcow2, iso, vhd, vhdx, tar.gz, img.gz, img.bz2, vhd.gz, vhdx.gz"; false echo "Unknown image extension in $image_filename, supported extensions: tgz, img, qcow2, iso, vhd, vhdx, tar.gz, img.gz, img.bz2, vhd.gz, vhdx.gz"; false
fi fi
openstack --os-url $GLANCE_SERVICE_PROTOCOL://$GLANCE_HOSTPORT --os-image-api-version 1 image set $image_name $magnum_image_property openstack --os-url $GLANCE_SERVICE_PROTOCOL://$GLANCE_HOSTPORT --os-image-api-version 2 image set $image_name $magnum_image_property
} }
# install_magnumclient() - Collect source and prepare # install_magnumclient() - Collect source and prepare

View File

@ -61,9 +61,7 @@ function create_test_data {
# image. Specifically, when we provide kernel and ramdisk images # image. Specifically, when we provide kernel and ramdisk images
# we need to select the 'ami' image. Otherwise, when we have # we need to select the 'ami' image. Otherwise, when we have
# qcow2 images, the format is 'bare'. # qcow2 images, the format is 'bare'.
# NOTE(prameswar): openstack cli not giving container format in export IMAGE_ID=$(openstack image list --property container_format=$container_format | grep -i $image_name | awk '{print $2}')
# command 'openstack image list' once it start supporting we have to add.
export IMAGE_ID=$(glance --os-image-api-version 1 image-list | grep $container_format | grep -i $image_name | awk '{print $2}')
#Get magnum_url #Get magnum_url
local magnum_api_ip=$(iniget /etc/magnum/magnum.conf api host) local magnum_api_ip=$(iniget /etc/magnum/magnum.conf api host)