You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Ansible-roles/kubernetes/tasks/k8s_setup.yml

10 lines
325 B
YAML

- name: Initialize Kubernetes Cluster
when: "inventory_hostname == groups['kubernetes'][0]"
command: kubeadm init --control-plane-endpoint={{ control_plane.dns_name }}
#--upload-certs
- name: Set environment-var for config
lineinfile:
dest: ~/.bashrc
line: "export KUBECONFIG=/etc/kubernetes/admin.conf"