Merge "Make tobiko-cleanup role not to stuck at stack deletion"

This commit is contained in:
Zuul 2021-11-25 18:45:58 +00:00 committed by Gerrit Code Review
commit e8a56bb2dc
1 changed files with 12 additions and 3 deletions

View File

@ -1,8 +1,17 @@
---
- name: "cleanup stacks created by tobiko tests"
- name: "cleanup Heat stacks created by Tobiko tests"
shell: |
source {{ stackrc_file }}
openstack stack list -f value -c 'Stack Name' | grep "^tobiko\." | xargs openstack stack delete --wait
openstack image list -f value -c Name | grep "^tobiko\." | xargs openstack image delete
openstack stack list -f value -c 'Stack Name' | \
grep "^tobiko\." | \
xargs -r openstack stack delete -y --wait
ignore_errors: yes
- name: "cleanup Glance images created by Tobiko tests"
shell: |
source {{ stackrc_file }}
openstack image list -f value -c 'Name' | \
grep "^tobiko\." | \
xargs -r openstack image delete
ignore_errors: yes