promenade/roles/deploy-bootstrap/tasks/prep-kubernetes.yaml
Brandon B. Jozsa 5fdb1d1bca initial commit
2017-04-20 06:41:05 -04:00

30 lines
669 B
YAML

---
- name: Ensures /etc/kubernetes dir exists
when:
bootstrap_enabled
file:
path: /etc/kubernetes
state: directory
- name: copy kubeconfig credentials
when:
bootstrap_enabled
command: cp /tmp/bootkube/assets/auth/kubeconfig /etc/kubernetes/kubeconfig
args:
creates: /etc/kubernetes/kubeconfig
- name: copy kubernetes manifests
when:
bootstrap_enabled
command: cp -a /tmp/bootkube/assets/manifests /etc/kubernetes/
args:
creates: /etc/kubernetes/manifests
- name: fetch kubeconfig
when:
bootstrap_enabled
fetch:
src: /etc/kubernetes/kubeconfig
dest: roles/deploy-kubelet/templates/kubeconfig
flat: yes