summaryrefslogtreecommitdiffstats
path: root/playbooks/adhoc/uninstall.yml
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2017-12-20 12:23:45 -0800
committerGitHub <noreply@github.com>2017-12-20 12:23:45 -0800
commit898b43c24a0db0f53cd272de0f3dec2a32bbc34e (patch)
tree99cb6240e59a7118b2b4c9be603efc7eaeaf4679 /playbooks/adhoc/uninstall.yml
parenta5de165b8e7113631a30ef0e4a20b5f74db073f0 (diff)
parente6c159afb4ba39a7266c750d43d6a5e911cc8f21 (diff)
downloadopenshift-898b43c24a0db0f53cd272de0f3dec2a32bbc34e.tar.gz
openshift-898b43c24a0db0f53cd272de0f3dec2a32bbc34e.tar.bz2
openshift-898b43c24a0db0f53cd272de0f3dec2a32bbc34e.tar.xz
openshift-898b43c24a0db0f53cd272de0f3dec2a32bbc34e.zip
Merge pull request #6516 from mgugino-upstream-stage/defact-is-containerized
Automatic merge from submit-queue. Remove openshift.common.{is_atomic|is_containerized} We set these variables using facts in init, no need to duplicate the logic all around the codebase.
Diffstat (limited to 'playbooks/adhoc/uninstall.yml')
-rw-r--r--playbooks/adhoc/uninstall.yml15
1 files changed, 7 insertions, 8 deletions
diff --git a/playbooks/adhoc/uninstall.yml b/playbooks/adhoc/uninstall.yml
index 584117e6b..0e0e2b425 100644
--- a/playbooks/adhoc/uninstall.yml
+++ b/playbooks/adhoc/uninstall.yml
@@ -18,9 +18,8 @@
# Since we're not calling openshift_facts we'll do this for now
- set_fact:
- is_atomic: "{{ ostree_output.rc == 0 }}"
- - set_fact:
- is_containerized: "{{ is_atomic or containerized | default(false) | bool }}"
+ openshift_is_atomic: "{{ ostree_output.rc == 0 }}"
+ openshift_is_containerized: "{{ ostree_output.rc == 0 or containerized | default(false) | bool }}"
# Stop services on all hosts prior to removing files.
- hosts: nodes
@@ -133,7 +132,7 @@
when: openshift_use_flannel | default(false) | bool
register: result
until: result is succeeded
- when: not is_atomic | bool
+ when: not openshift_is_atomic | bool
- shell: systemctl reset-failed
changed_when: False
@@ -363,7 +362,7 @@
- name: Remove packages
package: name={{ item }} state=absent
- when: not is_atomic | bool and openshift_remove_all | default(True) | bool
+ when: not openshift_is_atomic | bool and openshift_remove_all | default(True) | bool
with_items:
- atomic-openshift
- atomic-openshift-clients
@@ -487,14 +486,14 @@
- name: Stop additional atomic services
service: name={{ item }} state=stopped
- when: is_containerized | bool
+ when: openshift_is_containerized | bool
with_items:
- etcd_container
failed_when: false
- name: Remove packages
package: name={{ item }} state=absent
- when: not is_atomic | bool and openshift_remove_all | default(True) | bool
+ when: not openshift_is_atomic | bool and openshift_remove_all | default(True) | bool
with_items:
- etcd
- etcd3
@@ -554,7 +553,7 @@
- name: Remove packages
package: name={{ item }} state=absent
- when: not is_atomic | bool and openshift_remove_all | default(True) | bool
+ when: not openshift_is_atomic | bool and openshift_remove_all | default(True) | bool
with_items:
- haproxy
register: result