|
|
@ -56,10 +56,15 @@ |
|
|
|
with_items: |
|
|
|
with_items: |
|
|
|
- "kubelet" |
|
|
|
- "kubelet" |
|
|
|
- "kubeadm" |
|
|
|
- "kubeadm" |
|
|
|
- name: ensure /etc/default/kubelet exists |
|
|
|
- name: Check /etc/default/kubelet |
|
|
|
file: |
|
|
|
stat: |
|
|
|
path: /etc/default/kubelet |
|
|
|
path: /etc/default/kubelet |
|
|
|
state: file |
|
|
|
register: kubelet_defaults |
|
|
|
|
|
|
|
- name: Create /etc/default/kubelet |
|
|
|
|
|
|
|
copy: |
|
|
|
|
|
|
|
dest: /etc/default/kubelet |
|
|
|
|
|
|
|
content: "KUBELET_EXTRA_ARGS=\"--container-runtime-endpoint=unix:///run/containerd/containerd.sock\"" |
|
|
|
|
|
|
|
when: not kubelet_defaults.stat.exists |
|
|
|
- name: Set containerd in extraargs |
|
|
|
- name: Set containerd in extraargs |
|
|
|
blockinfile: |
|
|
|
blockinfile: |
|
|
|
dest: /etc/default/kubelet |
|
|
|
dest: /etc/default/kubelet |
|
|
|