Only create kubeadm compat cert dir link if it does not exist (#4840)
This commit is contained in:
parent
07cb8ebef7
commit
797bfd85b0
1 changed files with 9 additions and 0 deletions
|
@ -23,6 +23,14 @@
|
|||
- "{{ kube_manifest_dir }}"
|
||||
- "{{ kube_script_dir }}"
|
||||
|
||||
- name: Check if kubernetes kubeadm compat cert dir exists
|
||||
stat:
|
||||
path: "{{ kube_cert_compat_dir }}"
|
||||
register: kube_cert_compat_dir_check
|
||||
when:
|
||||
- inventory_hostname in groups['k8s-cluster']
|
||||
- kube_cert_dir != kube_cert_compat_dir
|
||||
|
||||
- name: Create kubernetes kubeadm compat cert dir (kubernetes/kubeadm issue 1498)
|
||||
file:
|
||||
src: "{{ kube_cert_dir }}"
|
||||
|
@ -31,6 +39,7 @@
|
|||
when:
|
||||
- inventory_hostname in groups['k8s-cluster']
|
||||
- kube_cert_dir != kube_cert_compat_dir
|
||||
- not kube_cert_compat_dir_check.stat.exists
|
||||
|
||||
- name: Create cni directories
|
||||
file:
|
||||
|
|
Loading…
Reference in a new issue