Open
Description
I'm trying to find if there is a way to provision PVs from multiple storage backends given a StatefulSet that has a single StorageClass defined in its volumeClaimTemplates
section.
Given a StatefulSet with a spec of spec.volumeClaimTemplates.storageClassName: test-sc
(pointing to a single StorageClass), and a storageClass with an hypothetical spec like:
apiVersion: storage.k8s.io/v1
kind: StorageClass
metadata:
name: test-sc
parameters:
backends:
- accessProtocol: fc1
csi.storage.k8s.io/controller-expand-secret-name: hpe-backend1
csi.storage.k8s.io/controller-expand-secret-namespace: hpe-storage
csi.storage.k8s.io/fstype: ext4
- accessProtocol: fc2
csi.storage.k8s.io/controller-expand-secret-name: hpe-backend2
csi.storage.k8s.io/controller-expand-secret-namespace: hpe-storage
csi.storage.k8s.io/fstype: ext4
imageFeatures: layering
pool: rbd
provisioner: csi.hpe.com
reclaimPolicy: Retain
volumeBindingMode: WaitForFirstConsumer
allowedTopologies:
- matchLabelExpressions:
- key: csi.hpe.com/zone
values:
- fc1
- fc2
Could it be possible to provision PVs from one backend or another depending on the zone or region in which the pod is scheduled?
Thank you very much for your help!
Metadata
Metadata
Assignees
Labels
No labels