try upgrade route
This commit is contained in:
parent
8febd3ba28
commit
70ef2ab9d3
1 changed files with 8 additions and 3 deletions
|
@ -61,7 +61,7 @@
|
|||
register: kubeadm_config
|
||||
|
||||
- name: kubeadm | Initialize first master
|
||||
command: timeout -k 240s 240s kubeadm init --config={{ kube_config_dir }}/kubeadm-config.yaml --skip-preflight-checks
|
||||
command: timeout -k 240s 240s kubeadm upgrade --config={{ kube_config_dir }}/kubeadm-config.yaml --skip-preflight-checks
|
||||
register: kubeadm_init
|
||||
#Retry is because upload config sometimes fails
|
||||
retries: 3
|
||||
|
@ -99,11 +99,16 @@
|
|||
with_items: "{{ kubeadm_certs.results }}"
|
||||
when: inventory_hostname != groups['kube-master']|first
|
||||
|
||||
- name: kubeadm | Initialize other masters
|
||||
command: timeout -k 240s 240s kubeadm init --config={{ kube_config_dir }}/kubeadm-config.yaml --skip-preflight-checks
|
||||
- name: kubeadm | Quick join other masters
|
||||
command: timeout -k 240s 240s kubeadm alpha phase {{ item }} --config={{ kube_config_dir }}/kubeadm-config.yaml --skip-preflight-checks
|
||||
register: kubeadm_init
|
||||
#Retry is because upload config sometimes fails
|
||||
retries: 3
|
||||
with_items:
|
||||
- controlplane apiserver
|
||||
- controlplane scheduler
|
||||
- controlplane controller-manager
|
||||
- bootstrap mark-master
|
||||
when: inventory_hostname != groups['kube-master']|first and (kubeadm_config.changed or not admin_conf.stat.exists or copy_kubeadm_certs.changed)
|
||||
|
||||
- name: kubeadm | Check service account key again
|
||||
|
|
Loading…
Reference in a new issue