mirror of https://github.com/easzlab/kubeasz.git
16 lines
482 B
YAML
16 lines
482 B
YAML
# to set up 'kube_master' nodes
|
|
- hosts: kube_master
|
|
roles:
|
|
- kube-lb
|
|
- kube-master
|
|
- kube-node
|
|
tasks:
|
|
- name: Making master nodes SchedulingDisabled
|
|
shell: "{{ bin_dir }}/kubectl cordon {{ inventory_hostname }} "
|
|
when: "inventory_hostname not in groups['kube_node']"
|
|
ignore_errors: true
|
|
|
|
- name: Setting master role name
|
|
shell: "{{ bin_dir }}/kubectl label node {{ inventory_hostname }} kubernetes.io/role=master --overwrite"
|
|
ignore_errors: true
|