Skip to content

What is GitOps

Key idea:

GitOps — paradigm where the entire system state (application manifests, infra) lives in Git, and agents in the cluster continuously sync actual to desired state. Term coined by Weaveworks in 2017. 4 principles: **Declarative**, **Versioned in Git**, **Automatically applied**, **Continuously reconciled**. Tools: ArgoCD (most popular), Flux CD, Jenkins X. Replaces: kubectl apply in CI/CD scripts.

Below: details, example, related terms, FAQ.

Details

  • Repo structure: dev manifests + prod manifests + environment overlays
  • Pull-based: agent in cluster pulls changes (vs CI push)
  • Drift detection: alerts if cluster state ≠ Git
  • Rollback = git revert + auto-sync
  • Auth: agents use read-only Git + K8s RBAC

Example

# ArgoCD Application
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
  name: my-app
spec:
  source:
    repoURL: https://github.com/me/manifests
    targetRevision: main
    path: apps/my-app
  destination:
    server: https://kubernetes.default.svc
    namespace: my-app
  syncPolicy:
    automated: { prune: true, selfHeal: true }

Related Terms

Learn more

Frequently Asked Questions

GitOps vs CI/CD?

Overlap. CI/CD — pipeline that deploys. GitOps — pattern of operating systems through Git as truth. GitOps often uses CI to build images + PR to manifest repo.

Secrets in Git — how?

NOT plain. Tools: SealedSecrets (encrypted YAML), External Secrets Operator (sync from Vault), SOPS (Mozilla).

Monorepo or split?

Split: app-code repo + manifests repo. Avoids CI reinvocation on manifest-only changes. More popular in 2026.