GitOps
In plain English
Plain definition
GitOps is a way of running infrastructure and applications where the Git repository is the authority on what should be running. Instead of an engineer applying changes directly to a server or cluster, the desired state is written into files stored in Git, and an automated agent continuously checks the live system against that stored state, correcting any drift it finds.
How GitOps works
GitOps pairs declarative, version-controlled manifests for infrastructure and application configuration with automated agents that continuously reconcile the observed state of a target system against the state declared in a Git repository. A change is proposed as a commit or pull request, reviewed through normal version-control workflows, and merged; a reconciliation controller (running inside or alongside the target environment) then detects the change and applies it, typically using a pull-based model rather than a push-based deployment pipeline.
The CNCF OpenGitOps principles define four properties: declarative state definitions, desired state that is versioned and immutable (the repository as the source of truth), state pulled automatically by agents, and a reconciliation loop that continuously enforces convergence rather than applying changes once and stopping.
Where the risk moves
GitOps changes where operational risk concentrates. Because every change to production state passes through Git, the commit history becomes an audit trail, and rollback becomes a revert of a commit rather than a manual undo of live changes. Imperative deployment pipelines are different. In them, the record of what was actually applied can drift from the record of what was intended.
Teams adopting GitOps must treat the Git repository itself as a critical control plane component. Access controls on the repository, branch protection, and review requirements matter as much as access controls on the target infrastructure, because a compromised or misconfigured repository can propagate unwanted state automatically.
What a GitOps setup needs
GitOps depends on a reconciliation controller with sufficient permissions to observe and modify the target environment, a declarative state format the controller can parse (commonly YAML manifests), and a Git repository the controller can poll or receive webhook notifications from. The controller runs a continuous loop: read declared state, read observed state, compute the difference, and apply corrective actions to close that difference.
GitOps is therefore not a deployment tool in its own right. It is an operating pattern that specific tools implement (typically referred to as GitOps operators or controllers). The pattern is most commonly associated with container orchestration platforms, where a controller reconciles declared workload manifests against a running cluster, but the same pattern is applicable to other declarative infrastructure domains.
A resource limit change, from commit to cluster
A team stores a set of deployment manifests in a Git repository. An engineer changes a resource limit value in a manifest file and opens a pull request. A reviewer approves the change and it is merged to the tracked branch. A reconciliation controller polling that repository detects the new commit, compares the updated manifest to the currently running configuration, and applies the resource limit change to the live workload. Nobody runs a manual apply command against the live environment: the controller does the convergence step itself.
What makes it GitOps
GitOps does not simply mean storing configuration in Git or using Git as part of a CI/CD pipeline. Storing configuration files in Git is necessary but not sufficient: the defining characteristic is the continuous reconciliation loop that enforces the declared state, not the version-control step alone. A pipeline that pushes changes from Git to production once, on a triggered basis, without ongoing drift correction, implements a Git-triggered deployment pattern rather than GitOps in the strict operational sense.
Terms that come up alongside GitOps
- Declarative configuration
- Continuous reconciliation
- Infrastructure as code
- Pull-based deployment
- Configuration drift
Further Reading
If you are evaluating GitOps for a specific environment, confirm the reconciliation controller’s version, supported manifest formats and permission model against current vendor documentation before relying on version-specific behaviour, as reconciliation semantics and default settings vary between controller implementations and change between releases.
Three checks before production
Before adopting a GitOps workflow in any environment beyond an isolated test, confirm the following in a non-production setting: that the reconciliation controller has only the minimum permissions needed to manage the intended resources (least privilege), that repository branch protection and review requirements are enforced before merge, and that a rollback path exists by reverting a commit and observing the controller reconcile back to the prior state. If you cannot demonstrate all three, the environment is not ready for production GitOps: escalate to a platform owner rather than proceeding.
Authoritative Sources
About this page
Credited to
Dates
Published
Corrections
No corrections are listed for this page. Some review sweeps corrected pages without naming each one; those are in the corrections log.
Was this useful?
Reports go to the site owner and are used to correct pages. Corrections are listed at /corrections.