ensure-kubernetes: fix missing 02-crio.conf

There was some recent changes to Minikube that added a hard
dependency on that file being there which are not caught by
upstream testing since they don't test with the "none" VM
driver.

This adds the file to workaround the issue so that it can
complete the bootstrap of the cluster.

Change-Id: I3869350ae620721ea4e755e50facd0291a7772d3
This commit is contained in:
Mohammed Naser 2022-03-24 19:28:39 -04:00
parent 57df8b9d6d
commit 65a3a8245b

View File

@ -25,6 +25,31 @@
loop_control: loop_control:
loop_var: zj_distro_os loop_var: zj_distro_os
- name: Workaround missing 02-crio.conf
# See: https://github.com/kubernetes/minikube/issues/13816
when: kubernetes_runtime == 'cri-o'
block:
- name: Add misisng crio.conf.d folder
file:
path: /etc/crio/crio.conf.d
state: directory
mode: 0755
become: true
- name: Fix missing 02-crio.conf
copy:
content: |
[crio.image]
# pause_image = ""
[crio.network]
# cni_default_network = ""
[crio.runtime]
# cgroup_manager = ""
dest: /etc/crio/crio.conf.d/02-crio.conf
mode: 0644
become: true
- name: Create .kube directory - name: Create .kube directory
file: file:
path: "{{ ansible_user_dir }}/.kube" path: "{{ ansible_user_dir }}/.kube"