summaryrefslogtreecommitdiffstats
path: root/playbooks/libvirt/openshift-cluster/terminate.yml
diff options
context:
space:
mode:
authorBrenton Leanhardt <bleanhar@redhat.com>2016-03-14 09:05:25 -0400
committerBrenton Leanhardt <bleanhar@redhat.com>2016-03-14 09:05:25 -0400
commit1b260a89cda950f919bfd62df17c786c3578bdfe (patch)
tree5f893d410f440b746f8bfff343ca8a3e473b4d97 /playbooks/libvirt/openshift-cluster/terminate.yml
parentac1da99a19a19868518e2271db24cac71c7cc2c4 (diff)
parentd4fa9b230d32fa11fafeab0cf347764108ab674a (diff)
downloadopenshift-1b260a89cda950f919bfd62df17c786c3578bdfe.tar.gz
openshift-1b260a89cda950f919bfd62df17c786c3578bdfe.tar.bz2
openshift-1b260a89cda950f919bfd62df17c786c3578bdfe.tar.xz
openshift-1b260a89cda950f919bfd62df17c786c3578bdfe.zip
Merge pull request #1578 from detiber/libvirt_fixes
Libvirt provider fixes
Diffstat (limited to 'playbooks/libvirt/openshift-cluster/terminate.yml')
-rw-r--r--playbooks/libvirt/openshift-cluster/terminate.yml8
1 files changed, 7 insertions, 1 deletions
diff --git a/playbooks/libvirt/openshift-cluster/terminate.yml b/playbooks/libvirt/openshift-cluster/terminate.yml
index f4749c28d..d6251ac83 100644
--- a/playbooks/libvirt/openshift-cluster/terminate.yml
+++ b/playbooks/libvirt/openshift-cluster/terminate.yml
@@ -45,12 +45,18 @@
- groups['oo_hosts_to_terminate']
- [ destroy, undefine ]
- - name: Delete VMs drives
+ - name: Delete VM drives
command: 'virsh -c {{ libvirt_uri }} vol-delete --pool {{ libvirt_storage_pool }} {{ item }}.qcow2'
args:
removes: '{{ libvirt_storage_pool_path }}/{{ item }}.qcow2'
with_items: groups['oo_hosts_to_terminate']
+ - name: Delete VM docker drives
+ command: 'virsh -c {{ libvirt_uri }} vol-delete --pool {{ libvirt_storage_pool }} {{ item }}-docker.qcow2'
+ args:
+ removes: '{{ libvirt_storage_pool_path }}/{{ item }}-docker.qcow2'
+ with_items: groups['oo_hosts_to_terminate']
+
- name: Delete the VM cloud-init image
file:
path: '{{ libvirt_storage_pool_path }}/{{ item }}_cloud-init.iso'