Add suport of Vsphere CSI driver 2.2.X versions (#7848)

This commit is contained in:
Eugene Artemenko
2021-08-09 18:19:38 +03:00
committed by GitHub
parent 82a9064d8d
commit e2b67b5700
6 changed files with 106 additions and 0 deletions

View File

@@ -39,8 +39,10 @@ spec:
value: /csi/csi.sock
- name: DRIVER_REG_SOCK_PATH
value: /var/lib/kubelet/plugins/csi.vsphere.vmware.com/csi.sock
{% if vsphere_csi_controller is version('v2.2.0', '<') %}
securityContext:
privileged: true
{% endif %}
volumeMounts:
- name: plugin-dir
mountPath: /csi
@@ -109,6 +111,12 @@ spec:
mountPropagation: "Bidirectional"
- name: device-dir
mountPath: /dev
{% if vsphere_csi_controller is version('v2.2.0', '>=') %}
- name: blocks-dir
mountPath: /sys/block
- name: sys-devices-dir
mountPath: /sys/devices
{% endif %}
ports:
- containerPort: 9808
name: healthz
@@ -150,6 +158,16 @@ spec:
- name: device-dir
hostPath:
path: /dev
{% if vsphere_csi_controller is version('v2.2.0', '>=') %}
- name: blocks-dir
hostPath:
path: /sys/block
type: Directory
- name: sys-devices-dir
hostPath:
path: /sys/devices
type: Directory
{% endif %}
tolerations:
- effect: NoExecute
operator: Exists