Skip to content

Commit 0d1f8e2

Browse files
killianmuldoonrbrtbnfgl
authored andcommitted
enable setting CNI directory paths in helm chart
enable setting the location of the CNI directories in the helm chart. Signed-off-by: Killian Muldoon <kmuldoon@nvidia.com>
1 parent 9bccfbb commit 0d1f8e2

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

chart/kube-flannel/templates/daemonset.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -130,10 +130,10 @@ spec:
130130
path: /run/flannel
131131
- name: cni-plugin
132132
hostPath:
133-
path: /opt/cni/bin
133+
path: {{ .Values.flannel.cniBinDir }}
134134
- name: cni
135135
hostPath:
136-
path: /etc/cni/net.d
136+
path: {{ .Values.flannel.cniConfDir }}
137137
- name: flannel-cfg
138138
configMap:
139139
name: kube-flannel-cfg

chart/kube-flannel/values.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,10 @@ flannel:
1616
image_cni:
1717
repository: ghcr.io/flannel-io/flannel-cni-plugin
1818
tag: v1.6.2-flannel1
19+
# cniBinDir is the directory to which the flannel CNI binary is installed.
20+
cniBinDir: "/opt/cni/bin"
21+
# cniConfDir is the directory where the CNI configuration is located.
22+
cniConfDir: "/etc/cni/net.d"
1923
# skipCNIConfigInstallation skips the installation of the flannel CNI config. This is useful when the CNI config is
2024
# provided externally.
2125
skipCNIConfigInstallation: false

0 commit comments

Comments
 (0)