Desired state and the loop
Scripts that ssh and docker run fail at placement, healing, rollouts, service addresses and multi-tenant isolation once you have dozens of machines. Key idea: store objects with spec (desired) and status (observed). Controllers reconcile forever: observe, compare, act, write status. The loop is level-triggered — it reacts to the gap between desired and observed, not to unmissable edge events. Missed events are fine; the next resync still sees "want 3, have 2" and creates a Pod. Borg and Omega used the thermostat analogy for the same reason.
Path of a Deployment apply: kubectl apply → API server persists to etcd → Deployment controller creates or updates a ReplicaSet → ReplicaSet creates Pods → scheduler binds Pods to nodes → kubelets pull images and start containers via CRI → readiness flips → status flows back up. If a Pod dies, the ReplicaSet sees too few replicas and creates another — healing without a human. If you delete a Pod you did not want deleted, the same loop recreates it; change the Deployment spec or scale to zero if you want it gone.
Reconciliation is eventually consistent. Briefly "wrong" states during rollouts are normal; design readiness probes and PodDisruptionBudgets so "briefly wrong" does not equal "serving errors."