Kubernetes : Storage Classes
We could have Storage classes with SSD, NVMe or NFS for example.
Applications could then "claim" storage depending on their need.
We could label storage classes, so its easier to choose among them.
We could label storage classes, so its easier to choose among them.
For example, we could have "Fast SSD" or "Slow SATA drives" as labels.
We can list the storage classes using the below command:
The default storage class is mentioned in the annotations.
Below is a simple example of a storage class Yaml file:
Remark:
The parameter "type" is specific to the provisioner.
The provisioner name could be for example " kubernetes.io/gce-pd" which provisions "gce-pd" storage, or "kubernetes.io/aws-ebs" for AWS.
We could see that its the default storage class in the annotations.
The default storage class is used to provision storage, if the claim - PVC - for the storage doesn’t mention the storage class to use.
The default storage class is used to provision storage, if the claim - PVC - for the storage doesn’t mention the storage class to use.
Below a simple example of a storage claim that doesn't include a storage class.
The default one will be used.
Comments