Provision Volume Using an Existing StorageClass
Learn how we can dynamically provision a volume using an existing StorageClass.
We'll cover the following...
In this and the next lesson, we’ll use StorageClasses to dynamically provision volumes on external systems. These lessons will only work on Regional GKE clusters. Refer to the Getting Kubernetes chapter on how to create a cluster on GKE. Every cloud and storage system has its own CSI plugin and configuration options; we can’t create examples for them all. Don’t be upset if you don’t have a Regional GKE cluster; you’ll still learn a lot by reading through the demos.
Use the following widget to execute all the commands for this lesson.
apiVersion: v1
kind: Pod
metadata:
name: volpod
spec:
volumes:
- name: data
persistentVolumeClaim:
claimName: pvc-prem
containers:
- name: ubuntu-ctr
image: ubuntu:latest
command:
- /bin/bash
- "-c"
- "sleep 60m"
volumeMounts:
- mountPath: /data
name: dataPlayground
Use an existing StorageClass
The ...