Desired State
Cheat sheet · https://pcornel.dk/topic.php?topic=5157
Answer
Desired State is the authoritative description of what managed resources or services should look like after automation has converged.
Remember
- Desired state ≠ current state; configuration intent can exist while runtime reality differs.
- Desired state ≠ every property; some fields may be generated, learned or intentionally unmanaged.
- Repository value ≠ authoritative automatically; ownership and promotion rules determine which source wins.
- Desired configuration ≠ service acceptance; the configured state must still produce the required operational outcome.
First checks
- Desired state in git — source of truth
terraform show— state as known by toolkubectl get <obj> -o yaml— declared spec
Verify in this order
git (desired) → tool → target
Where it usually breaks
Desired state proves what should be true according to an authoritative intent source; it does not prove the target currently matches it.
Configuration/input → graph/state refresh → plan → provider API request → provider terminal result → resource read-back → effective service state → workload.
Desired State automation boundary map
| Boundary | Healthy evidence | Suspicious evidence |
|---|---|---|
| Intent / inputs | Owner, scope and authoritative inputs are explicit and versioned where applicable | Hidden defaults, stale inventory or competing sources of truth |
| Decision / execution | Plan or decision is explainable and actions are bounded per target | Blind fan-out, implicit assumptions or success based only on executor status |
| State / verification | Target is re-observed and acceptance criteria prove the intended outcome | No read-back, perpetual drift, partial side effects or unresolved exceptions |
| Recovery / evidence | Retry, rollback or escalation behavior is defined and auditable | Unknown partial completion, unsafe retry or evidence lost during remediation |
Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=5157