Using EFS volumes with your application
EFS is a shared storage platform unlike EBS, so while at the Kubernetes level, you have the same objects, SC, PV, and PVCs, the way you access the storage and how the storage is created are quite different.
The following diagram illustrates the relationship between an EFS instance/volume and the Kubernetes PV, PVC, and Pod:
Figure 12.3 – EFS volumes
Although we have installed the CSI driver, we can’t provision volumes without an EFS instance and mount targets in the required subnets. Let’s look at how we can create them next.
Creating the EFS instance and mount targets
You can do this in a variety of ways, but we will use the AWS CLI. Let’s start by creating the EFS filesystem and retrieving the filesystem ID. The following command will create the EFS instance and filter the response to only return FileSystemId
. Please adjust the –region
parameter to account for the Region...