For example, if you want to create a StorageClass that will create Amazon EBS Volume of type General Purpose SSD (gp2), you'd define a StorageClass manifest like so:
kind: StorageClassapiVersion: storage.k8s.io/v1metadata: name: standardprovisioner: kubernetes.io/aws-ebsparameters: type: gp2reclaimPolicy: Retain
Here's what each field means (required fields are marked with an asterik (*):
- apiVersion: The StorageClass object is provided in the storage.k8s.io API group.
- *provisioner: The name of a provisioner that would prepare new storage spaces on-demand. For instance, if a Pod requests 10 GB of block storage from the standard StorageClass, then the kubernetes.io/aws-ebs provisioner will interact directly with AWS ...