How do I pre-provision a volume for a statefulset in Kubernetes on AWS?

1/8/2020

I am using the pattern suggested here with selectors and a pre-provsioned persistent volume (pv). I am able to provision the pv in advance, and I deploy the statefulset, but if I describe the pvc, it throws the error below. I am using Kubernetes 1.10

Error Failed to provision volume with StorageClass "gp2-encrypted": claim.Spec.Selector is not supported for dynamic provisioning on AWS

Question: How do I pre-provision a pv (with resulting persistent volume claim (pvc)) for a statefulset?

-- Banoona
kubernetes-pvc
kubernetes-statefulset

0 Answers