summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorScott Dodson <sdodson@redhat.com>2017-02-10 17:00:21 -0500
committerGitHub <noreply@github.com>2017-02-10 17:00:21 -0500
commitbda3bf8cbc75d1dd9a1c4add106af3feb0563b24 (patch)
treecf9dd2ffbb23404be5a5d497e0a57edbbaad4a47
parenta4f64f2452d980580823a0676282e25eb0dec561 (diff)
parentac23d6fc37dd98be8ad4ecc5a924d482e6e74957 (diff)
downloadopenshift-bda3bf8cbc75d1dd9a1c4add106af3feb0563b24.tar.gz
openshift-bda3bf8cbc75d1dd9a1c4add106af3feb0563b24.tar.bz2
openshift-bda3bf8cbc75d1dd9a1c4add106af3feb0563b24.tar.xz
openshift-bda3bf8cbc75d1dd9a1c4add106af3feb0563b24.zip
Merge pull request #3309 from jcantrill/bz_1420229_metrics_fail_on_upgrade
Bz 1420229 metrics fail on upgrade
-rw-r--r--roles/openshift_metrics/tasks/install_metrics.yaml14
1 files changed, 14 insertions, 0 deletions
diff --git a/roles/openshift_metrics/tasks/install_metrics.yaml b/roles/openshift_metrics/tasks/install_metrics.yaml
index 66925c113..66a3abdbd 100644
--- a/roles/openshift_metrics/tasks/install_metrics.yaml
+++ b/roles/openshift_metrics/tasks/install_metrics.yaml
@@ -34,6 +34,20 @@
file_content: "{{ item.content | b64decode | from_yaml }}"
with_items: "{{ object_defs.results }}"
+- command: >
+ {{openshift.common.client_binary}}
+ --config={{mktemp.stdout}}/admin.kubeconfig
+ get rc
+ -l metrics-infra
+ -o name
+ -n {{openshift_metrics_project}}
+ register: existing_metrics_rc
+ changed_when: no
+
+- name: Scaling down cluster to recognize changes
+ include: stop_metrics.yaml
+ when: "{{ existing_metrics_rc.stdout_lines | length > 0 }}"
+
- name: Scaling up cluster
include: start_metrics.yaml
tags: openshift_metrics_start_cluster