summaryrefslogtreecommitdiffstats
path: root/playbooks
diff options
context:
space:
mode:
authorBrenton Leanhardt <bleanhar@redhat.com>2015-10-27 13:42:11 -0400
committerBrenton Leanhardt <bleanhar@redhat.com>2015-10-28 10:22:44 -0400
commit7558c4e35e076704624fdffa347a08cf7f3a804f (patch)
tree4c5d76b772269d1912a5d136d3b7f342eeea9368 /playbooks
parentbab6549b2fdac9df97af7cc0e6b018c8d8758291 (diff)
downloadopenshift-7558c4e35e076704624fdffa347a08cf7f3a804f.tar.gz
openshift-7558c4e35e076704624fdffa347a08cf7f3a804f.tar.bz2
openshift-7558c4e35e076704624fdffa347a08cf7f3a804f.tar.xz
openshift-7558c4e35e076704624fdffa347a08cf7f3a804f.zip
Adding uninstall support for Atomic Host
Diffstat (limited to 'playbooks')
-rw-r--r--playbooks/adhoc/uninstall.yml11
1 files changed, 10 insertions, 1 deletions
diff --git a/playbooks/adhoc/uninstall.yml b/playbooks/adhoc/uninstall.yml
index 40db668da..8cc5b9406 100644
--- a/playbooks/adhoc/uninstall.yml
+++ b/playbooks/adhoc/uninstall.yml
@@ -1,6 +1,6 @@
# This deletes *ALL* Origin, Atomic Enterprise Platform and OpenShift
# Enterprise content installed by ansible. This includes:
-#
+#
# configuration
# containers
# example templates and imagestreams
@@ -13,6 +13,14 @@
sudo: yes
tasks:
+ - name: Detecting Operating System
+ shell: ls /run/ostree-booted
+ ignore_errors: yes
+ register: ostree_output
+
+ - set_fact:
+ is_atomic: ostree_output.rc == 0
+
- service: name={{ item }} state=stopped
with_items:
- atomic-enterprise-master
@@ -33,6 +41,7 @@
- origin-node
- yum: name={{ item }} state=absent
+ when: not is_atomic
with_items:
- atomic-enterprise
- atomic-enterprise-master