How to configure a Persistent Volume Claim using AWS EFS and ReadWriteMany?
You will need to setup the EFS-provisioner in your cluster. Mounting EFS is still not supported by the default Kubernetes distribution and as such you need this extension: https://github.com/kubernetes-incubator/external-storage/tree/master/aws/efs
You'll need to set up it's storage class:
kind: StorageClassapiVersion: storage.k8s.io/v1beta1metadata: name: aws-efsprovisioner: example.com/aws-efs
And then write PVC's of the type:
kind: PersistentVolumeClaimapiVersion: v1metadata: name: efs annotations: volume.beta.kubernetes.io/storage-class: "aws-efs"spec: accessModes: - ReadWriteMany resources: requests: storage: 1Mi
Don't mind the storage size, although it's not used by EFS, Kubernetes requires you to set something there for it to work.