World map

 

BM: Baca dalam Bahasa Melayu

World K4: Notes, Lockers & Packages

API deprecations and kyaml

You will learn: to fix YAML that uses a retired API, and to read KYAML.

Checked with Kubernetes 1.37 on 31 Oct 2026

The problem

You are here: cluster kind-dev namespace default
kubectl apply fails: resource mapping not found, no matches for kind Deployment in version extensions/v1beta1. Terminal output: $ kubectl apply -f old-shop.yaml error: resource mapping not found for name: "shop" namespace: "" from "old-shop.yaml": no matches for kind "Deployment" in version "extensions/v1beta1" ensure CRDs are installed first

You copied a Deployment from an old blog. kubectl says no matches for kind "Deployment" in version "extensions/v1beta1". Plain words: nobody takes that form anymore.

Watch

Tap each point on the timeline.

An API deprecation: An old form the office will stop taking. Move to the new apiVersion before it goes. is an old form the office will stop taking. First comes a warning. A few releases later, the form is gone.

Try it

Bring the old Deployment up to date.

Fix the manifest, then press Apply.

shop.yaml18 lines

Predict

A file uses an API that is deprecated, but still served. What happens on kubectl apply?

Pick one answer.

Watch

bash
kubectl create configmap settings --from-literal=GREETING=Selamat --from-literal=SPICY=3 --dry-run=client -o kyaml
---
{
kind: "ConfigMap",
apiVersion: "v1",
metadata: {
name: "settings",
},
data: {
GREETING: "Selamat",
SPICY: "3",
},
}
kubectl create configmap with dry run and -o kyaml prints the ConfigMap with braces, and every string in double quotes.

kubectl 1.37 can print KYAML: Strict YAML from kubectl: every string in quotes, braces around maps. Any YAML reader still reads it.: YAML written strictly. Every string sits in double quotes. Braces wrap each map, so spaces never change the meaning.

Predict

Plain YAML. A ConfigMap says SPICY: yes. What does the API server get?

Pick one answer.

Check

True or not? Swipe each one.

Swipe right for good, left for needs work. Or use the buttons.

1 / 4

An old tutorial says extensions/v1beta1. Switch the Deployment to apps/v1.

An old tutorial says extensions/v1beta1. Switch the Deployment to apps/v1.

You did it!

You can now update retired APIs and read KYAML.

Go deeper (optional)

The kubectl convert plugin rewrites old files, but check its defaults. Where the story breaks: kind’s lockers sit on one stall. If that stall’s disk dies, the locker dies too. And notes on the wall are readable by anyone allowed to read ConfigMaps.

Real rep (optional), on a practice cluster:

Real mission

  1. kubectl api-resources
  2. kubectl explain deployment
  3. kubectl create deployment x --image=nginx:1.29-alpine --dry-run=client -o kyaml

0 of 3 steps done · Your ticks are saved.