feat: add kubeletDir in chart config

This commit is contained in:
Angelos Kolaitis 2022-01-28 11:25:43 +02:00
parent e2bc26bee7
commit f7df83d902
No known key found for this signature in database
GPG Key ID: 66AC4122BBC46C5C
5 changed files with 10 additions and 7 deletions

View File

@ -40,6 +40,7 @@ The following table lists the configurable parameters of the latest NFS CSI Driv
| `driver.mountPermissions` | mounted folder permissions name | `0777` | `driver.mountPermissions` | mounted folder permissions name | `0777`
| `feature.enableFSGroupPolicy` | enable `fsGroupPolicy` on a k8s 1.20+ cluster | `true` | | `feature.enableFSGroupPolicy` | enable `fsGroupPolicy` on a k8s 1.20+ cluster | `true` |
| `feature.enableInlineVolume` | enable inline volume | `false` | | `feature.enableInlineVolume` | enable inline volume | `false` |
| `kubeletDir` | alternative kubelet directory | `/var/lib/kubelet` |
| `image.nfs.repository` | csi-driver-nfs image | `mcr.microsoft.com/k8s/csi/nfs-csi` | | `image.nfs.repository` | csi-driver-nfs image | `mcr.microsoft.com/k8s/csi/nfs-csi` |
| `image.nfs.tag` | csi-driver-nfs image tag | `latest` | | `image.nfs.tag` | csi-driver-nfs image tag | `latest` |
| `image.nfs.pullPolicy` | csi-driver-nfs image pull policy | `IfNotPresent` | | `image.nfs.pullPolicy` | csi-driver-nfs image pull policy | `IfNotPresent` |

View File

@ -95,7 +95,7 @@ spec:
periodSeconds: 30 periodSeconds: 30
volumeMounts: volumeMounts:
- name: pods-mount-dir - name: pods-mount-dir
mountPath: /var/lib/kubelet/pods mountPath: {{ .Values.kubeletDir }}/pods
mountPropagation: "Bidirectional" mountPropagation: "Bidirectional"
- mountPath: /csi - mountPath: /csi
name: socket-dir name: socket-dir
@ -103,7 +103,7 @@ spec:
volumes: volumes:
- name: pods-mount-dir - name: pods-mount-dir
hostPath: hostPath:
path: /var/lib/kubelet/pods path: {{ .Values.kubeletDir }}/pods
type: Directory type: Directory
- name: socket-dir - name: socket-dir
emptyDir: {} emptyDir: {}

View File

@ -60,7 +60,7 @@ spec:
- --kubelet-registration-path=$(DRIVER_REG_SOCK_PATH) - --kubelet-registration-path=$(DRIVER_REG_SOCK_PATH)
env: env:
- name: DRIVER_REG_SOCK_PATH - name: DRIVER_REG_SOCK_PATH
value: /var/lib/kubelet/plugins/csi-nfsplugin/csi.sock value: {{ .Values.kubeletDir }}/plugins/csi-nfsplugin/csi.sock
- name: KUBE_NODE_NAME - name: KUBE_NODE_NAME
valueFrom: valueFrom:
fieldRef: fieldRef:
@ -109,19 +109,19 @@ spec:
- name: socket-dir - name: socket-dir
mountPath: /csi mountPath: /csi
- name: pods-mount-dir - name: pods-mount-dir
mountPath: /var/lib/kubelet/pods mountPath: {{ .Values.kubeletDir }}/pods
mountPropagation: "Bidirectional" mountPropagation: "Bidirectional"
resources: {{- toYaml .Values.node.resources.nfs | nindent 12 }} resources: {{- toYaml .Values.node.resources.nfs | nindent 12 }}
volumes: volumes:
- name: socket-dir - name: socket-dir
hostPath: hostPath:
path: /var/lib/kubelet/plugins/csi-nfsplugin path: {{ .Values.kubeletDir }}/plugins/csi-nfsplugin
type: DirectoryOrCreate type: DirectoryOrCreate
- name: pods-mount-dir - name: pods-mount-dir
hostPath: hostPath:
path: /var/lib/kubelet/pods path: {{ .Values.kubeletDir }}/pods
type: Directory type: Directory
- hostPath: - hostPath:
path: /var/lib/kubelet/plugins_registry path: {{ .Values.kubeletDir }}/plugins_registry
type: Directory type: Directory
name: registration-dir name: registration-dir

View File

@ -32,6 +32,8 @@ feature:
enableFSGroupPolicy: true enableFSGroupPolicy: true
enableInlineVolume: false enableInlineVolume: false
kubeletDir: /var/lib/kubelet
controller: controller:
name: csi-nfs-controller name: csi-nfs-controller
replicas: 1 replicas: 1