2017-09-09 20:38:03 +00:00
|
|
|
---
|
|
|
|
- name: Kubernetes Apps | Lay down dashboard template
|
|
|
|
template:
|
2018-02-05 08:17:51 +00:00
|
|
|
src: "{{ item.file }}.j2"
|
|
|
|
dest: "{{ kube_config_dir }}/{{ item.file }}"
|
2017-09-09 20:38:03 +00:00
|
|
|
with_items:
|
2018-02-05 08:17:51 +00:00
|
|
|
- { file: dashboard.yml, type: deploy, name: kubernetes-dashboard }
|
2017-09-09 20:38:03 +00:00
|
|
|
register: manifests
|
|
|
|
when: inventory_hostname == groups['kube-master'][0]
|
|
|
|
|
|
|
|
- name: Kubernetes Apps | Start dashboard
|
|
|
|
kube:
|
2019-04-23 17:37:23 +00:00
|
|
|
name: "{{ item.item.name }}"
|
2018-03-30 11:29:13 +00:00
|
|
|
namespace: "kube-system"
|
2018-02-05 08:17:51 +00:00
|
|
|
kubectl: "{{ bin_dir }}/kubectl"
|
2019-04-23 17:37:23 +00:00
|
|
|
resource: "{{ item.item.type }}"
|
|
|
|
filename: "{{ kube_config_dir }}/{{ item.item.file }}"
|
2017-09-09 20:38:03 +00:00
|
|
|
state: "latest"
|
2019-04-23 17:37:23 +00:00
|
|
|
with_items: "{{ manifests.results }}"
|
2017-09-09 20:38:03 +00:00
|
|
|
when: inventory_hostname == groups['kube-master'][0]
|