declarative configuration

Describing the end result you want in files and letting a tool work out the steps, rather than typing each step as a command.

In more detail

Applying the same declaration twice changes nothing the second time, because the system already matches. Imperative commands do one action right now and leave no reviewable record. Declarative files are what make code review, rollback and GitOps possible.

Examples

kubectl apply -f web-deployment.yaml   # declarative
kubectl delete pod web   # imperative

Related terms

Taught in

References