Kubernetes CoreArchitecture and the API
4 lessons · about 52 minutes of reading · free
This page is the public course outline. Lessons, labs, tools and exams open after you sign in to your free account.
Sign in and start
In short
How Kubernetes is built and how you talk to it: declarative state, control plane and nodes, the API and kubectl, namespaces and labels.
Before you start: Level 1.
What you'll learn
- You declare desired state; Kubernetes converges actual state to it
- Controllers run observe, compare, act loops continuously
- Self-healing, scaling, rollouts and service discovery come from these loops
- Hand edits to managed objects get reconciled away; change the source instead
- kube-apiserver is the only door; etcd holds all state
- Scheduler places pods; controller manager runs reconciliation loops
- kubelet runs pods and reports status; kube-proxy makes Services work
- Components watch the API server; they don't call each other directly
- Every object: apiVersion, kind, metadata, spec (and status from the system)
- Imperative for speed and generation; declarative apply from Git for production
- kubectl diff before apply; --dry-run=client -o yaml to scaffold
- api-resources, explain and -o yaml find anything
Lessons
1. Why Kubernetes: declarative orchestration
Desired state, reconciliation loops and why orchestration replaced hand-run servers.
Sign in to open the lesson
2. Control plane and nodes
The API server, etcd, scheduler, controller manager, kubelet, kube-proxy and the runtime, and how they cooperate.
Sign in to open the lesson
3. The API, objects, YAML and kubectl
apiVersion, kind, metadata, spec and status; imperative versus declarative kubectl; and finding anything with explain and api-resources.
Sign in to open the lesson
4. Namespaces, labels, selectors and annotations
How Kubernetes groups, selects and describes objects, and why labels drive almost everything.
Sign in to open the lesson
Common questions
Is 'kubectl scale deploy web --replicas=5' imperative or declarative?
Imperative: a one-off command, not a stored file.
Which component runs Services' iptables or IPVS rules?
kube-proxy (or an eBPF CNI replacement).
Which API group are Deployments in?
apps (apps/v1).
Can a Deployment's selector be changed after creation?
No: spec.selector is immutable in apps/v1.