2017-09-09 20:38:03 +00:00
|
|
|
---
|
2017-11-09 21:59:30 +00:00
|
|
|
- name: Kubernetes Apps | Delete old kubernetes-dashboard resources
|
|
|
|
kube:
|
|
|
|
name: "kubernetes-dashboard"
|
|
|
|
kubectl: "{{bin_dir}}/kubectl"
|
|
|
|
resource: "{{ item }}"
|
|
|
|
state: absent
|
2017-11-13 19:59:31 +00:00
|
|
|
with_items:
|
|
|
|
- 'ClusterRoleBinding'
|
2017-11-09 21:59:30 +00:00
|
|
|
tags:
|
|
|
|
- upgrade
|
|
|
|
|
2017-09-09 20:38:03 +00:00
|
|
|
- name: Kubernetes Apps | Lay down dashboard template
|
|
|
|
template:
|
|
|
|
src: "{{item.file}}"
|
|
|
|
dest: "{{kube_config_dir}}/{{item.file}}"
|
|
|
|
with_items:
|
2017-11-09 21:59:30 +00:00
|
|
|
- {file: dashboard.yml.j2, 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:
|
|
|
|
name: "{{item.item.name}}"
|
|
|
|
namespace: "{{system_namespace}}"
|
|
|
|
kubectl: "{{bin_dir}}/kubectl"
|
|
|
|
resource: "{{item.item.type}}"
|
|
|
|
filename: "{{kube_config_dir}}/{{item.item.file}}"
|
|
|
|
state: "latest"
|
|
|
|
with_items: "{{ manifests.results }}"
|
|
|
|
when: inventory_hostname == groups['kube-master'][0]
|