diff options
author | Lénaïc Huard <lhuard@amadeus.com> | 2015-06-05 17:44:33 +0200 |
---|---|---|
committer | Lénaïc Huard <lhuard@amadeus.com> | 2015-07-17 14:31:34 +0200 |
commit | fb4083bb920d193c2f292b49f370667029c317ba (patch) | |
tree | fd6af5ed5d884623acee3eb772cbfbb467a6e151 /playbooks/libvirt/openshift-cluster/terminate.yml | |
parent | e0211ca67ce18fc9f74d0a9c82cf14a28f395e4d (diff) | |
download | openshift-fb4083bb920d193c2f292b49f370667029c317ba.tar.gz openshift-fb4083bb920d193c2f292b49f370667029c317ba.tar.bz2 openshift-fb4083bb920d193c2f292b49f370667029c317ba.tar.xz openshift-fb4083bb920d193c2f292b49f370667029c317ba.zip |
Implement RHEL subscription for enterprise deployment type
Diffstat (limited to 'playbooks/libvirt/openshift-cluster/terminate.yml')
-rw-r--r-- | playbooks/libvirt/openshift-cluster/terminate.yml | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/playbooks/libvirt/openshift-cluster/terminate.yml b/playbooks/libvirt/openshift-cluster/terminate.yml index b173a09dd..8f00812a9 100644 --- a/playbooks/libvirt/openshift-cluster/terminate.yml +++ b/playbooks/libvirt/openshift-cluster/terminate.yml @@ -15,6 +15,23 @@ ansible_sudo: "{{ deployment_vars[deployment_type].sudo }}" with_items: groups[cluster_group] | default([]) +- name: Unsubscribe VMs + hosts: oo_hosts_to_terminate + vars_files: + - vars.yml + roles: + - role: rhel_unsubscribe + when: deployment_type == "enterprise" and + ansible_distribution == "RedHat" and + lookup('oo_option', 'rhel_skip_subscription') | default(rhsub_skip, True) | + default('no', True) | lower in ['no', 'false'] + +- name: Terminate instance(s) + hosts: localhost + gather_facts: no + vars_files: + - vars.yml + tasks: - name: Destroy VMs virt: name: '{{ item[0] }}' |