Why should environment state be declared rather than scripted?
IntermediateConceptGitOps Principles & Delivery Models
Answer
A script describes how to get from one state to another and depends on the starting point; running it twice or from an unexpected state can break things. A declaration describes the end state, so a controller can compute the difference from any starting point, re-run safely (idempotence), detect drift, and rebuild from nothing. That is what makes continuous reconciliation and DR possible.
More on GitOps Principles & Delivery Models
What is GitOps, in one or two sentences?BeginnerWhat are the four OpenGitOps principles?BeginnerExplain push-based vs pull-based deployment.BeginnerIs "we keep our Kubernetes YAML in Git and CI runs `kubectl apply`" GitOps?BeginnerWhat are the main benefits of GitOps that you would pitch to a team?BeginnerWhat are the honest downsides or pain points of GitOps?Intermediate