summaryrefslogtreecommitdiffstats
path: root/playbooks/libvirt/openshift-cluster/terminate.yml
diff options
context:
space:
mode:
authorJason DeTiberus <detiber@gmail.com>2016-07-21 09:52:11 -0400
committerGitHub <noreply@github.com>2016-07-21 09:52:11 -0400
commita355349a98cecec1d10e7d166aa70d8e77df20e1 (patch)
treedbca76441caf841b0b0e7578497c84bb125a6b2a /playbooks/libvirt/openshift-cluster/terminate.yml
parent893ffb6ec88b82d4607d9777ab741db1845d4f1e (diff)
parent887ba6a2a7263985d5f644e37e5428f0a8bd5166 (diff)
downloadopenshift-a355349a98cecec1d10e7d166aa70d8e77df20e1.tar.gz
openshift-a355349a98cecec1d10e7d166aa70d8e77df20e1.tar.bz2
openshift-a355349a98cecec1d10e7d166aa70d8e77df20e1.tar.xz
openshift-a355349a98cecec1d10e7d166aa70d8e77df20e1.zip
Merge pull request #2187 from lhuard1A/bin_cluster_libvirt_ansible_2.1
Fix libvirt provider for Ansible 2.1.0.0
Diffstat (limited to 'playbooks/libvirt/openshift-cluster/terminate.yml')
-rw-r--r--playbooks/libvirt/openshift-cluster/terminate.yml12
1 files changed, 6 insertions, 6 deletions
diff --git a/playbooks/libvirt/openshift-cluster/terminate.yml b/playbooks/libvirt/openshift-cluster/terminate.yml
index baef911f9..df5c52f2d 100644
--- a/playbooks/libvirt/openshift-cluster/terminate.yml
+++ b/playbooks/libvirt/openshift-cluster/terminate.yml
@@ -15,7 +15,7 @@
groups: oo_hosts_to_terminate
ansible_ssh_user: "{{ deployment_vars[deployment_type].ssh_user }}"
ansible_become: "{{ deployment_vars[deployment_type].become }}"
- with_items: groups[cluster_group] | default([])
+ with_items: '{{ groups[cluster_group] | default([]) }}'
- name: Unsubscribe VMs
hosts: oo_hosts_to_terminate
@@ -42,30 +42,30 @@
command: '{{ item[1] }}'
uri: '{{ libvirt_uri }}'
with_nested:
- - groups['oo_hosts_to_terminate']
+ - "{{ groups['oo_hosts_to_terminate'] }}"
- [ destroy, undefine ]
- 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']
+ 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']
+ with_items: "{{ groups['oo_hosts_to_terminate'] }}"
- name: Delete the VM cloud-init image
file:
path: '{{ libvirt_storage_pool_path }}/{{ item }}_cloud-init.iso'
state: absent
- with_items: groups['oo_hosts_to_terminate']
+ with_items: "{{ groups['oo_hosts_to_terminate'] }}"
- name: Remove the cloud-init config directory
file:
path: '{{ libvirt_storage_pool_path }}/{{ item }}_configdrive/'
state: absent
- with_items: groups['oo_hosts_to_terminate']
+ with_items: "{{ groups['oo_hosts_to_terminate'] }}"