advanced
Argo CD
Use GitOps reconciliation to deploy Kubernetes manifests from Git while tracking drift, sync status, and rollback history.
Argo CD is a GitOps controller for Kubernetes. Desired state lives in Git; the controller reconciles clusters toward that state; drift, sync health, and rollbacks become visible operations.
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: web
spec:
source:
repoURL: https://github.com/org/k8s-manifests
path: apps/web
destination:
server: https://kubernetes.default.svc
namespace: production
syncPolicy:
automated:
prune: true
CI builds and pushes images; Argo CD deploys manifests that reference image digests or tags. Sync waves order dependencies; health checks gate promotion.
On interviews: pull-based GitOps versus push deploy, drift detection, separating build CI from deploy reconciliation, secret management in clusters.
Common pitfalls: bad manifests in Git still break production; manual `kubectl` drift fights GitOps; conflating image build pipeline with deployment controller.
The trade-off is declarative cluster state versus Kubernetes operational learning curve.
Checklist:
- Keep desired state in Git.
- Watch sync and application health.
- Separate image build from manifest reconciliation.
- Manage secrets outside plain Git when required.