2022-12-01 07:26:00 +00:00
|
|
|
{{/*
|
|
|
|
Return the appropriate sidecar images based on k8s version
|
|
|
|
*/}}
|
|
|
|
{{- define "csi-powerstore.attacherImage" -}}
|
|
|
|
{{- if eq .Capabilities.KubeVersion.Major "1" }}
|
2023-03-28 14:02:53 +00:00
|
|
|
{{- if and (ge (trimSuffix "+" .Capabilities.KubeVersion.Minor) "22") (le (trimSuffix "+" .Capabilities.KubeVersion.Minor) "26") -}}
|
|
|
|
{{- print "k8s.gcr.io/sig-storage/csi-attacher:v4.2.0" -}}
|
2022-12-01 07:26:00 +00:00
|
|
|
{{- end -}}
|
|
|
|
{{- end -}}
|
|
|
|
{{- end -}}
|
|
|
|
|
|
|
|
{{- define "csi-powerstore.provisionerImage" -}}
|
|
|
|
{{- if eq .Capabilities.KubeVersion.Major "1" }}
|
2023-03-28 14:02:53 +00:00
|
|
|
{{- if and (ge (trimSuffix "+" .Capabilities.KubeVersion.Minor) "22") (le (trimSuffix "+" .Capabilities.KubeVersion.Minor) "26") -}}
|
|
|
|
{{- print "k8s.gcr.io/sig-storage/csi-provisioner:v3.4.0" -}}
|
2022-12-01 07:26:00 +00:00
|
|
|
{{- end -}}
|
|
|
|
{{- end -}}
|
|
|
|
{{- end -}}
|
|
|
|
|
|
|
|
{{- define "csi-powerstore.snapshotterImage" -}}
|
|
|
|
{{- if eq .Capabilities.KubeVersion.Major "1" }}
|
2023-03-28 14:02:53 +00:00
|
|
|
{{- if and (ge (trimSuffix "+" .Capabilities.KubeVersion.Minor) "22") (le (trimSuffix "+" .Capabilities.KubeVersion.Minor) "26") -}}
|
|
|
|
{{- print "k8s.gcr.io/sig-storage/csi-snapshotter:v6.2.1" -}}
|
2022-12-01 07:26:00 +00:00
|
|
|
{{- end -}}
|
|
|
|
{{- end -}}
|
|
|
|
{{- end -}}
|
|
|
|
|
|
|
|
{{- define "csi-powerstore.resizerImage" -}}
|
|
|
|
{{- if eq .Capabilities.KubeVersion.Major "1" }}
|
2023-03-28 14:02:53 +00:00
|
|
|
{{- if and (ge (trimSuffix "+" .Capabilities.KubeVersion.Minor) "22") (le (trimSuffix "+" .Capabilities.KubeVersion.Minor) "26") -}}
|
|
|
|
{{- print "k8s.gcr.io/sig-storage/csi-resizer:v1.7.0" -}}
|
2022-12-01 07:26:00 +00:00
|
|
|
{{- end -}}
|
|
|
|
{{- end -}}
|
|
|
|
{{- end -}}
|
|
|
|
|
|
|
|
{{- define "csi-powerstore.registrarImage" -}}
|
|
|
|
{{- if eq .Capabilities.KubeVersion.Major "1" }}
|
2023-03-28 14:02:53 +00:00
|
|
|
{{- if and (ge (trimSuffix "+" .Capabilities.KubeVersion.Minor) "22") (le (trimSuffix "+" .Capabilities.KubeVersion.Minor) "26") -}}
|
|
|
|
{{- print "k8s.gcr.io/sig-storage/csi-node-driver-registrar:v2.6.3" -}}
|
2022-12-01 07:26:00 +00:00
|
|
|
{{- end -}}
|
|
|
|
{{- end -}}
|
|
|
|
{{- end -}}
|
|
|
|
|
|
|
|
{{- define "csi-powerstore.healthmonitorImage" -}}
|
|
|
|
{{- if eq .Capabilities.KubeVersion.Major "1" }}
|
2023-03-28 14:02:53 +00:00
|
|
|
{{- if and (ge (trimSuffix "+" .Capabilities.KubeVersion.Minor) "22") (le (trimSuffix "+" .Capabilities.KubeVersion.Minor) "26") -}}
|
|
|
|
{{- print "gcr.io/k8s-staging-sig-storage/csi-external-health-monitor-controller:v0.8.0" -}}
|
2022-12-01 07:26:00 +00:00
|
|
|
{{- end -}}
|
|
|
|
{{- end -}}
|
2022-12-15 17:25:29 +00:00
|
|
|
{{- end -}}
|
|
|
|
|
|
|
|
{{/*
|
|
|
|
Return true if storage capacity tracking is enabled and is supported based on k8s version
|
|
|
|
*/}}
|
|
|
|
{{- define "csi-powerstore.isStorageCapacitySupported" -}}
|
|
|
|
{{- if eq .Values.storageCapacity.enabled true -}}
|
|
|
|
{{- if and (eq .Capabilities.KubeVersion.Major "1") (ge (trimSuffix "+" .Capabilities.KubeVersion.Minor) "24") -}}
|
|
|
|
{{- true -}}
|
|
|
|
{{- end -}}
|
|
|
|
{{- end -}}
|
|
|
|
{{- end -}}
|