Skip to content
CKAStorageSingle nodeMedium

Default StorageClass

Scenario cka-sto-003 · about 8 minutes · 6 points · 7 grader checks

Make an existing StorageClass the cluster default and provision a PVC without naming a class.

  • storage
  • storageclass
  • default
  • pvc

What you will practise

  • Set the default StorageClass annotation
  • Create a PVC that relies on the default class
  • Observe binding behaviour of a WaitForFirstConsumer class

Start this lab

With the CLI installed and signed in, this command provisions a single node cluster on your Mac, applies the scenario setup and prints the task below.

goldenkube start cka-sto-003

Task

The task text exactly as the CLI shows it. Solve it on the cluster, then run goldenkube submit.

The cluster has a StorageClass "local-path" that is currently NOT the default class. Make "local-path" the cluster default StorageClass. Then, in namespace "data" (create it if missing), create a PersistentVolumeClaim named "auto-pvc" requesting 1Gi, accessMode ReadWriteOnce, WITHOUT specifying any storageClassName, so that the default class is applied. Finally create a Pod named "auto-pod" (image nginx:1.27) in namespace "data" that mounts "auto-pvc" at /mnt/auto. The PVC must be Bound and the pod Running.

Requirements and details

Certification
CKA · Certified Kubernetes Administrator
Domain
Storage
Difficulty
Medium
Cluster topology
Single node
Cluster features
Storage
Recommended time
8 minutes
Points
6
Grader checks
7
Kubernetes version
1.37
Minimum CLI version
0.1.0
Scenario version
1
Published

Grading runs locally: 7 state checks read your cluster when you submit; the scenario passes when every check passes. Hints, the reference solution and the check definitions are available only inside the CLI, not on this page.

CKAStorageMedium

Manual PersistentVolume and matching claim

Create a hostPath PersistentVolume and a PersistentVolumeClaim that binds to it.

Single node · ~7 min · 6 points

  • storage
  • pv
  • pvc
  • hostpath

goldenkube start cka-sto-002

CKAStorageMedium

StatefulSet with volumeClaimTemplates

Create a headless Service and a StatefulSet whose pod gets its own dynamically provisioned PVC.

Two nodes · ~10 min · 7 points · Storage

  • storage
  • statefulset
  • headless
  • volumeclaimtemplate
  • pvc

goldenkube start cka-sto-004

Independent community project, not affiliated with or endorsed by CNCF or The Linux Foundation. Lab results are practice feedback, not an exam score.