summaryrefslogtreecommitdiffstats
path: root/roles/openshift_metrics/tasks/main.yaml
diff options
context:
space:
mode:
authorJeff Cantrill <jcantrill@users.noreply.github.com>2016-12-14 14:40:36 -0500
committerJeff Cantrill <jcantril@redhat.com>2017-01-17 11:45:04 -0500
commit84b1c4848f610c5792809bb2e9e5b0d8f77ea50c (patch)
tree0d47f74415ed4b547fdaafa8a897ee75ca0f0ecb /roles/openshift_metrics/tasks/main.yaml
parentee931f90dbab01596bd90fa8007ac49de5178a17 (diff)
downloadopenshift-84b1c4848f610c5792809bb2e9e5b0d8f77ea50c.tar.gz
openshift-84b1c4848f610c5792809bb2e9e5b0d8f77ea50c.tar.bz2
openshift-84b1c4848f610c5792809bb2e9e5b0d8f77ea50c.tar.xz
openshift-84b1c4848f610c5792809bb2e9e5b0d8f77ea50c.zip
copy admin cert for use in subsequent tasks (#8)
Diffstat (limited to 'roles/openshift_metrics/tasks/main.yaml')
-rw-r--r--roles/openshift_metrics/tasks/main.yaml12
1 files changed, 10 insertions, 2 deletions
diff --git a/roles/openshift_metrics/tasks/main.yaml b/roles/openshift_metrics/tasks/main.yaml
index adedd4069..d4bafdc30 100644
--- a/roles/openshift_metrics/tasks/main.yaml
+++ b/roles/openshift_metrics/tasks/main.yaml
@@ -1,7 +1,7 @@
---
- name: check that hawkular_metrics_hostname is set
fail: msg='the openshift_metrics_hawkular_metrics_hostname variable is required'
- when: "{{ openshift_metrics_hawkular_metrics_hostname is not defined }}"
+ when: openshift_metrics_hawkular_metrics_hostname is not defined
- name: check the value of openshift_metrics_hawkular_cassandra_storage_type
fail:
@@ -21,6 +21,13 @@
file: path={{mktemp.stdout}}/templates state=directory mode=0755
changed_when: False
+- name: Copy the admin client config(s)
+ command: >
+ cp {{ openshift.common.config_base}}/master/admin.kubeconfig {{ mktemp.stdout }}/admin.kubeconfig
+ changed_when: False
+ check_mode: no
+ tags: metrics_init
+
- include: "{{role_path}}/tasks/install_metrics.yaml"
when: openshift_metrics_install_metrics | default(false) | bool
@@ -29,7 +36,8 @@
- name: create objects
command: >
- {{ openshift.common.client_binary }} -n '{{ openshift_metrics_project }}'
+ {{ openshift.common.client_binary }} -n {{ openshift_metrics_project }}
+ --config={{ mktemp.stdout }}/admin.kubeconfig
apply -f {{ item }}
with_fileglob:
- "{{ mktemp.stdout }}/templates/*.yaml"