summaryrefslogtreecommitdiffstats
path: root/playbooks/libvirt/openshift-cluster/terminate.yml
diff options
context:
space:
mode:
authorJason DeTiberus <jdetiber@redhat.com>2016-03-09 12:19:05 -0500
committerJason DeTiberus <jdetiber@redhat.com>2016-03-10 08:37:57 -0500
commitd4fa9b230d32fa11fafeab0cf347764108ab674a (patch)
tree84ae4e8f122e0e5e2e363c28e0a64f09af723b8b /playbooks/libvirt/openshift-cluster/terminate.yml
parentc9301aa9682846a35dac6948cc0efb5d4628a3ad (diff)
downloadopenshift-d4fa9b230d32fa11fafeab0cf347764108ab674a.tar.gz
openshift-d4fa9b230d32fa11fafeab0cf347764108ab674a.tar.bz2
openshift-d4fa9b230d32fa11fafeab0cf347764108ab674a.tar.xz
openshift-d4fa9b230d32fa11fafeab0cf347764108ab674a.zip
Libvirt provider fixes
- Use difference filter instead of reject/equalto - add ability to override vcpu and memory config for vms - add a dedicated drive for docker storage
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'