# GitOps

> Run your systems from a Git repo. A helper keeps them in line with it.

**Field:** Software Development  
**Category:** DevOps & Cloud  
**Also known as:** Git Ops, GitOps Workflow, Argo CD, Flux CD

## Think of it like

Think of it like a thermostat. You set the number you want, and it keeps fixing the room to match.

## Definition

GitOps is a way to run systems where Git holds the wanted state of everything. The setup is written as files, and every change is a commit. An agent pulls those files and makes the live system match. It keeps checking, and it fixes any drift it finds. Tools like Argo CD and Flux do this for Kubernetes.

## Example

Jack changes the number of app copies from 3 to 5 in a pull request. Once it is merged, the agent adds two copies.

## Why it matters

Each change is checked and saved in history. To undo one, you use git revert.

## Common mistake

Changing the live system by hand. The agent sees the drift and puts it back the way Git says.

## Three principles

- **Git holds the truth.** The wanted state is in files.
- **Pulled in.** An agent fetches the changes.
- **Always matched.** Drift gets fixed on its own.

## Related terms

- [Infrastructure as Code (IaC)](https://learn.benibix.com/term/development/infrastructure-as-code)
- [Configuration Drift](https://learn.benibix.com/term/development/configuration-drift)
- [Git Revert](https://learn.benibix.com/term/development/git-revert)
- [Kubernetes (K8s)](https://learn.benibix.com/term/infrastructure/kubernetes)
- [Continuous Deployment](https://learn.benibix.com/term/development/continuous-deployment)

![Two ways to keep servers set up the same. On the left, configuration management with Ansible: a playbook in YAML is pushed over SSH from one control machine to three servers, with no agent on them. On the right, GitOps, lit up: the wanted state lives in a Git repository, and an agent inside the cluster pulls it and keeps fixing any difference it finds.](https://learn.benibix.com/diagrams/dev3-config-mgmt.svg)

---

Source: https://learn.benibix.com/term/development/gitops
Author: Behnia Zarei (a developer in Vienna, Austria, who builds and teaches data, AI and business intelligence at BENIBIX)
Publisher: BENIBIX Learn (https://learn.benibix.com/)
Last updated: 2026-11-18
Licence: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Quote freely with attribution.
