diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2017-11-15 14:54:16 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-11-15 14:54:16 -0800 |
commit | 6cfc4a162cff36bb2ba7bb482135060e76c5d5a1 (patch) | |
tree | 42fca971b5b412b6d2e16e701fb0db815b1e1660 | |
parent | 24d2349eb93272eb71a9d6f8a5fc28f2b04881e9 (diff) | |
parent | eaf2b01987f5bd3e96d0a4fdb9d841698e25c977 (diff) | |
download | openshift-6cfc4a162cff36bb2ba7bb482135060e76c5d5a1.tar.gz openshift-6cfc4a162cff36bb2ba7bb482135060e76c5d5a1.tar.bz2 openshift-6cfc4a162cff36bb2ba7bb482135060e76c5d5a1.tar.xz openshift-6cfc4a162cff36bb2ba7bb482135060e76c5d5a1.zip |
Merge pull request #6099 from zgalor/create_cfgmap_before_statefulset
Automatic merge from submit-queue.
Create prometheus configmaps before statefulset
Originally statefulset was created before configmaps and the pod would have a "FailedMount" warning for a few seconds until the configmaps are created.
Now the configmaps are created before the statefulset to avoid that warning.
-rw-r--r-- | roles/openshift_prometheus/tasks/install_prometheus.yaml | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/roles/openshift_prometheus/tasks/install_prometheus.yaml b/roles/openshift_prometheus/tasks/install_prometheus.yaml index 00c3c1987..21da4bc9d 100644 --- a/roles/openshift_prometheus/tasks/install_prometheus.yaml +++ b/roles/openshift_prometheus/tasks/install_prometheus.yaml @@ -148,25 +148,6 @@ selector: "{{ openshift_prometheus_alertbuffer_pvc_pv_selector }}" when: openshift_prometheus_alertbuffer_storage_type == 'pvc' -# create prometheus stateful set -- name: Set prometheus template - template: - src: prometheus.j2 - dest: "{{ tempdir }}/templates/prometheus.yaml" - vars: - namespace: "{{ openshift_prometheus_namespace }}" -# prom_replicas: "{{ openshift_prometheus_replicas }}" - -- name: Set prometheus stateful set - oc_obj: - state: "{{ state }}" - name: "prometheus" - namespace: "{{ openshift_prometheus_namespace }}" - kind: statefulset - files: - - "{{ tempdir }}/templates/prometheus.yaml" - delete_after: true - # prometheus configmap # Copy the additional rules file if it is defined - name: Copy additional rules file to host @@ -236,3 +217,22 @@ namespace: "{{ openshift_prometheus_namespace }}" from_file: alertmanager.yml: "{{ tempdir }}/alertmanager.yml" + +# create prometheus stateful set +- name: Set prometheus template + template: + src: prometheus.j2 + dest: "{{ tempdir }}/templates/prometheus.yaml" + vars: + namespace: "{{ openshift_prometheus_namespace }}" +# prom_replicas: "{{ openshift_prometheus_replicas }}" + +- name: Set prometheus stateful set + oc_obj: + state: "{{ state }}" + name: "prometheus" + namespace: "{{ openshift_prometheus_namespace }}" + kind: statefulset + files: + - "{{ tempdir }}/templates/prometheus.yaml" + delete_after: true |