Deploying Snapshot and Clones Workloads
This example is more complex and is composed of six different stages:
Stage 1: Create VolumeSnapshotClass.
Stage 2: Create Example PVC and POD.
Stage 3: Take a Snapshot from the PVC created in Stage #2.
Stage 4: Create a PVC from the Snapshot created in Stage #3 and create a POD that uses it.
Stage 5: Create a PVC from the PVC created in Stage #4 and create a POD that uses it.
Stage 6: Uninstall Snapshot Workloads.
The examples are dependent on one another, so you must run them in order.
For Helm to deploy the snaps chart in stages, we introduce the mandatory variable snaps.stage The chart supports the following stages:
snapshot-class
example-pvc
snapshot-from-pvc
pvc-from-snapshot
pvc-from-pvc
Stage 1: Create VolumeSnapshotClass
Create a VolumeSnapshotClass:
Stage 2: Create Example PVC and POD
Running the following command:
Will output:
Verify that PV, PVC are created and in Bounded state, and that POD is in Running state.
Stage 3: Take a Snapshot from the PVC created in Stage 2
Create a snapshot from the previously created PVC named example-pvc.
Will output:
Verify that VolumeSnapshot and VolumeSnapshotContent were created, and READYTOUSE status is true.
Stage 4: Create a PVC from the Snapshot created in Stage 3 and create a POD that uses it
Create a PVC from the previously taken Snapshot named example-snapshot.
Will output:
Verify that PV, PVC are created and in Bounded state, and that POD is in Running state.
We see the PV, PVC and PODs from Stage #2 as well.
Stage 5: Create a PVC from the PVC created in Stage 3 and create a POD that uses it
Create a PVC from the previously taken Snapshot named example-snapshot.
Will output:
Verify that PV, PVC were created and in Bounded state, and that POD is in Running state.
We see the PV, PVC and PODs from Stages #2 and #4 as well.
Stage 6: Uninstall Snapshot Workloads
If we list the releases installed, we will see:
The installation must be in reverse order of the deployment.
After each uninstall, we need to verify that all related resources were released before continuing to the next uninstall.
Uninstall pvc-from-pvc:
In order to verify that all resources are deleted, the following command should return no entry:
Uninstall pvc-from-snapshot:
In order to verify that all resources are deleted, the following command should return no entry:
Uninstall snapshot-from-pvc:
In order to verify that all resources are deleted, the following command should return no entry:
Uninstall example-pvc:
Verify that all resources are gone:
Delete VolumeSnapshotClass:
© 2026 Lightbits Labs™