Skip to content

Commit 2958368

Browse files
authored
Merge pull request #1434 from neoaggelos/feat/kubelet-path
Support node.kubeletPath helm chart value
2 parents 0c2bc34 + 23adeb9 commit 2958368

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

charts/aws-efs-csi-driver/templates/node-daemonset.yaml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ spec:
9696
{{- end }}
9797
volumeMounts:
9898
- name: kubelet-dir
99-
mountPath: /var/lib/kubelet
99+
mountPath: {{ .Values.node.kubeletPath }}
100100
mountPropagation: "Bidirectional"
101101
- name: plugin-dir
102102
mountPath: /csi
@@ -135,7 +135,7 @@ spec:
135135
- name: ADDRESS
136136
value: /csi/csi.sock
137137
- name: DRIVER_REG_SOCK_PATH
138-
value: /var/lib/kubelet/plugins/efs.csi.aws.com/csi.sock
138+
value: {{ printf "%s/plugins/efs.csi.aws.com/csi.sock" (trimSuffix "/" .Values.node.kubeletPath) }}
139139
- name: KUBE_NODE_NAME
140140
valueFrom:
141141
fieldRef:
@@ -172,15 +172,15 @@ spec:
172172
volumes:
173173
- name: kubelet-dir
174174
hostPath:
175-
path: /var/lib/kubelet
175+
path: {{ .Values.node.kubeletPath }}
176176
type: Directory
177177
- name: plugin-dir
178178
hostPath:
179-
path: /var/lib/kubelet/plugins/efs.csi.aws.com/
179+
path: {{ printf "%s/plugins/efs.csi.aws.com/" (trimSuffix "/" .Values.node.kubeletPath) }}
180180
type: DirectoryOrCreate
181181
- name: registration-dir
182182
hostPath:
183-
path: /var/lib/kubelet/plugins_registry/
183+
path: {{ printf "%s/plugins_registry/" (trimSuffix "/" .Values.node.kubeletPath) }}
184184
type: Directory
185185
- name: efs-state-dir
186186
hostPath:
@@ -196,4 +196,4 @@ spec:
196196
type: DirectoryOrCreate
197197
{{- with .Values.node.volumes }}
198198
{{- toYaml . | nindent 8 }}
199-
{{- end }}
199+
{{- end }}

charts/aws-efs-csi-driver/values.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -187,6 +187,7 @@ node:
187187
env: []
188188
volumes: []
189189
volumeMounts: []
190+
kubeletPath: /var/lib/kubelet
190191

191192
storageClasses: []
192193
# Add StorageClass resources like:

0 commit comments

Comments
 (0)