Read the API's bookkeeping

  • 12 min
  • 6 steps
  • The API and the loop

Steps

0 of 6 done

Use discovery to find group versions, watch generation and resourceVersion respond to different kinds of write, and release an object held by a finalizer.

  1. Step 1 of 6

    Find the API group and version this cluster serves CronJobs under, by asking the cluster rather than the documentation.

    Checked against what your commands print.

  2. Step 2, not started: pdb.yaml was written for a cluster before 1.25. Try applying it, read why it is refused, then find the version of its group that this cluster does serve.

  3. Step 3, not started: Add the label team=storefront to the web Deployment, then confirm that its generation did not change.

  4. Step 4, not started: Change web to run nginx:1.31, then wait until the deployment controller reports that it has seen the change.

  5. Step 5, not started: Delete the app-config ConfigMap without waiting for it to go away, then show the field that records when deletion was requested.

  6. Step 6, not started: No controller owns example.com/hold, so nothing will ever remove it. Release the ConfigMap so the API server can finish deleting it.

Lab terminal

Cluster time 50 seconds
kind cluster kx, Kubernetes 1.37.
Each step is checked as you work.
​
Tab completes. Up and Down recall.
Type help for more.
Terminal keys

Enter runs the command. Tab completes, and the arrow keys recall earlier commands. Control C stops a watch. On an empty line, or after Escape, Tab moves focus out of the terminal.