...

/

Provision Volume by Creating a New StorageClass

Provision Volume by Creating a New StorageClass

Learn how we can dynamically provision a volume by creating a new StorageClass.

We'll cover the following...

Create and use a new StorageClass

In this lesson, we’ll create a new StorageClass and use it to dynamically provision and use a new volume.

Use the following widget to execute all the commands for this lesson.

apiVersion: storage.k8s.io/v1
kind: StorageClass
metadata:
  name: sc-fast-repl
provisioner: pd.csi.storage.gke.io
parameters:
  type: pd-ssd
  replication-type: regional-pd
volumeBindingMode: WaitForFirstConsumer
reclaimPolicy: Retain
Playground

We’ll create the StorageClass defined in the sc-gke-fast-repl.yml file in the storage folder. It defines a StorageClass called sc-fast-repl with the following properties:

  • Fast SSD storage (type: pd-ssd)

  • Replicated (replication-type: regional-pd) ...