Skip to content

Commit

Permalink
Don't create calico CNI dir when not using calico
Browse files Browse the repository at this point in the history
Signed-off-by: Pat Riehecky <[email protected]>
  • Loading branch information
jcpunk committed May 30, 2023
1 parent 94e33bd commit db2412a
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions roles/kubernetes/preinstall/tasks/0050-create_directories.yml
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,22 @@
- kube-router
- bootstrap-os

- name: Create calico cni directories
file:
path: "{{ item }}"
state: directory
owner: "{{ kube_owner }}"
mode: 0755
with_items:
- "/var/lib/calico"
when:
- kube_network_plugin == "calico"
- inventory_hostname in groups['k8s_cluster']
tags:
- network
- calico
- bootstrap-os

- name: Create local volume provisioner directories
file:
path: "{{ local_volume_provisioner_storage_classes[item].host_dir }}"
Expand Down

0 comments on commit db2412a

Please sign in to comment.