Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

tazuna state diff

Compares the Build result of each Manager with the State stored in the cluster and outputs per-resource differences. Does not modify the cluster.

tazuna state diff [-f tazuna.yaml]

Behavior

  1. Load tazuna.yaml.
  2. For each Manifest, call the Manager’s Build to construct “the resources that should currently be generated from tazuna.yaml.”
  3. Reconcile with the in-cluster State and classify each resource into one of the following.
Diff typeMeaning
addedPresent in the Build result, absent from State
modifiedPresent in both, but with different content hashes
removedPresent in State, absent from the Build result
always-syncClassification that skips diff computation and is always synchronized. Secrets derived from type: genesissecret go here

Does not evaluate context_matches. Only read access to the cluster is performed; nothing is modified.

Difference from state drift

Both state diff and state drift show a “diff,” but they compare different things.

Aspectstate diffstate drift
Compared againstBuild result vs StateState vs live cluster
Changes detectedChanges on the tazuna.yaml sideManual kubectl apply / manual deletion
Output categoriesadded / modified / removed / always-synclive-drifted / live-missing

By switching the command you use depending on whether the drift is “an update on the tazuna.yaml side not yet applied” or “the cluster side touched directly,” you can build low-noise monitoring.

Flag

No specific flags besides the global flags.

Examples

tazuna state diff
tazuna state diff -f tazuna.yaml