glance/playbooks/post-check-metadata-injection.yaml
Dan Smith c023445d05 Make our import-workflow job also convert images to raw
This enables image conversion on the import-workflow job so that we at
least run those code paths somewhere in CI.

Change-Id: Ie4a9171f002b42a13c1786268057bdc0ab3804d0
2020-08-27 07:29:12 -07:00

20 lines
812 B
YAML

- hosts: controller
tasks:
- name: Run glance validation script
shell:
executable: /bin/bash
cmd: |
source /opt/stack/devstack/openrc
set -xe
cirrosimg=$(openstack image list -f csv -c ID -c Name --quote none | grep cirros | cut -d , -f 1)
echo "Dumping the cirros image for debugging..."
openstack image show $cirrosimg
echo "Checking that the cirros image was decorated with metdata on import..."
openstack image list -f value -c Name --property 'glance_devstack_test=doyouseeme?' | grep cirros
echo "Checking that the cirros image was converted to raw on import..."
openstack image show $cirrosimg -f value -c disk_format | grep '^raw$'
environment: '{{ zuul | zuul_legacy_vars }}'