summaryrefslogtreecommitdiffstats
path: root/roles/openshift_prometheus/tasks/main.yaml
diff options
context:
space:
mode:
authorZohar Galor <zgalor@redhat.com>2017-11-20 16:21:47 +0200
committerZohar Galor <zgalor@redhat.com>2017-11-20 16:21:47 +0200
commit24ac787110041ce99e1589cd621e07bb14e546ba (patch)
tree92ff07938b0c36240eba317cc8515c128f3a8ce4 /roles/openshift_prometheus/tasks/main.yaml
parent6b14b105e0998c63a248160fb6887f86b8f3b549 (diff)
downloadopenshift-24ac787110041ce99e1589cd621e07bb14e546ba.tar.gz
openshift-24ac787110041ce99e1589cd621e07bb14e546ba.tar.bz2
openshift-24ac787110041ce99e1589cd621e07bb14e546ba.tar.xz
openshift-24ac787110041ce99e1589cd621e07bb14e546ba.zip
Fix uninstall option for prometheus
Only remove prometheus namespace when uninstalling. This will remove all the contained objects. bz: https://bugzilla.redhat.com/show_bug.cgi?id=1492544
Diffstat (limited to 'roles/openshift_prometheus/tasks/main.yaml')
-rw-r--r--roles/openshift_prometheus/tasks/main.yaml6
1 files changed, 4 insertions, 2 deletions
diff --git a/roles/openshift_prometheus/tasks/main.yaml b/roles/openshift_prometheus/tasks/main.yaml
index 5cc9a67eb..a62babaa7 100644
--- a/roles/openshift_prometheus/tasks/main.yaml
+++ b/roles/openshift_prometheus/tasks/main.yaml
@@ -21,8 +21,10 @@
changed_when: False
- include: install_prometheus.yaml
- vars:
- state: "{{ openshift_prometheus_state }}"
+ when: openshift_prometheus_state == 'present'
+
+- include: uninstall_prometheus.yaml
+ when: openshift_prometheus_state == 'absent'
- name: Delete temp directory
file: