/devops-skills:gitopsfrom devops-skills
Establishes Git as the single source of truth for deployed state with a pull-based controller reconciling the cluster to match a repo. Covers config repo vs app repo separation, environment promotion via merge, and rollback as revert commit.
Ships in devops-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
GitOps is not "we keep our YAML in Git." It is a specific operational model: a controller inside the cluster continuously pulls desired state from a repo and reconciles reality toward it, so the repo is not documentation of what was deployed — it is the only correct description of what should be deployed, and anything else is drift waiting to be corrected. That shift from push to pull is what makes the rest of the practice fall into place: audit trail, rollback, and promotion all become Git operations instead of pipeline scripts.
If the cluster state and the repo disagree, the cluster is wrong, not the repo.
The repo where application code lives and the repo the reconciler watches should not be the same
repo, and should almost never be the same commit. CI in the app repo builds an image, pushes it to
a registry, and then makes a small, automated commit to the config repo bumping an image tag — it
never touches the cluster directly. This split matters because it lets you reason about "what is
deployed" by reading one small, low-churn repo instead of grepping application history, and it lets
the config repo have its own review rules (e.g. required approval for prod) independent of code
review norms. See ci-pipelines for the build side and artifact-management for where the image
actually lives.
Done when: deploying a new version never requires a human to run a deploy command by hand.
Represent each environment (dev, staging, prod) as its own path or overlay, and promote a change by
merging or copying it forward — not by re-running a pipeline with a different target flag. A pull
request from staging/ into prod/ is a promotion event with a diff, a reviewer, and a timestamp,
which is a far stronger artifact than a Jenkins job log claiming the same thing happened. Kustomize
overlays or Helm values-per-environment both work; what matters is that the mechanism of promotion
is a Git operation everyone can see. See environment-management for how environments are defined
and release-management for gating promotion on approvals or criteria.
Done when: you can answer "what's different between staging and prod" with a single git diff.
The moment a human or a CI job applies manifests directly, the repo stops being the source of
truth and starts being a suggestion. Every path to changing cluster state — including emergency
fixes — must go through a commit, even if that commit is made and merged in under a minute during
an incident. Lock this down with cluster RBAC that denies write access to everyone except the
reconciler's service account. The discipline pays for itself the first time someone asks "who
changed this and why" and the answer is a commit message instead of a shrug. For the controller
enforcing this, see argocd-operations; for the RBAC mechanics see kubernetes-security.
Done when: no human credential in the system can mutate cluster state directly.
If promotion is a merge, rollback is a revert: git revert the bad commit, push, and let the
reconciler pull the previous known-good state back down. This only works if manifests are fully
declarative and self-contained — no imperative migration steps hiding outside the diff, no
"also run this script" in a runbook. Treat any deploy that can't be undone by reverting its commit
as a bug in the manifests, not an acceptable exception. This is also why rollback should be tested
before it's needed, not discovered live during an incident.
git revert <bad-commit> && git push # reconciler pulls this within its sync interval
Done when: the last rollback in this repo was a plain revert with no manual cleanup afterward.
Config belongs in Git; secret values do not, even encrypted-at-rest-in-a-private-repo is not good
enough once you consider history, forks, and CI log leakage. Reference secrets from Git — a
SealedSecret, an ExternalSecret pointing at a vault, an SOPS-encrypted file if you truly must
commit ciphertext — rather than storing plaintext or something trivially reversible. The rule is
simple: a leaked clone of this repo should leak zero credentials. See secrets-management for the
storage and rotation mechanics this skill deliberately does not cover.
Done when: cloning this repo and reading every file yields no usable credential.
Drift — cluster state diverging from the repo — will happen: a debugging kubectl edit, a
mutating webhook, an autoscaler writing back replica counts. Configure the reconciler to detect and
either auto-heal or loudly flag drift rather than silently tolerating it, and exclude only the
specific fields (like HPA-managed replicas) that are expected to diverge. Undetected drift is how
"the repo is the source of truth" quietly becomes false over weeks. See observability for
alerting when reconciliation itself falls behind or fails.
Done when: any out-of-band cluster change is either corrected automatically or surfaced as an alert within one reconciliation cycle.
State the repo layout chosen (app/config split, directory-per-environment or branch-per-environment), how promotion and rollback are performed, and where secrets are referenced from. Call out any remaining path where someone can still apply changes outside Git — that gap, if it exists, is the actual state of your source of truth, and naming it beats claiming the model is fully enforced.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
Git, Kubernetes, Argo CD, Helm
npx claudepluginhub arjunprabhulal/devops-skills --plugin devops-skills88 skills in this plugin
/alertingCovers designing alerts that page a human only when a human needs to act — symptom-based alerting over cause-based, multi-window burn-rate alerts on error budgets, severity tiers that route between page/ticket/dashboard, requiring every page to link a runbook, and tuning out alert fatigue. Use this whenever the user is writing a new alert rule, asking why on-call is paged too often or missing real incidents, choosing an alert threshold, or designing severity routing. For the SLO the burn-rate math comes from use `slo-definition`, and for what a runbook should contain use `runbooks`./api-gatewayCovers the managed front-door pattern for APIs — request routing, centralized auth, rate limiting and quotas, request/response shaping, and recognizing when a gateway helps versus becomes a bottleneck or single point of failure. Use this whenever the user is designing an API entry point, adding rate limits or quotas, centralizing auth for several backend services, transforming a request between an external and internal contract, or debugging a gateway timeout. For east-west traffic between internal services use `service-connectivity`, and for token issuance details use `iam-access-management`./argocd-operationsCovers running Argo CD day to day — structuring app-of-apps, choosing sync policies and waves, reading health versus sync status correctly, and unsticking a degraded or hung Application. Use this whenever the user mentions Argo CD, an Application stuck "Progressing" or "OutOfSync," app-of-apps or ApplicationSets, sync waves and hooks, or asks why a deploy shows synced but the workload is unhealthy. For the underlying model this tool implements use `gitops`; for automated canary analysis on top of it use `progressive-delivery`; for the workloads it manages use `kubernetes-operations`./artifact-managementVersions, stores, and promotes build outputs — registries, immutability, build-once-promote-many, retention and garbage collection, and provenance metadata. Use this whenever the user sets up an artifact or container registry, asks how to promote a build between environments without rebuilding, needs a retention or cleanup policy, or wants to trace where an artifact came from. For an image's contents and size use `image-optimization`; for vulnerability scanning use `image-scanning`./autoscalingCovers scaling Kubernetes workloads and nodes to demand — HPA on the right metric, VPA, cluster autoscaler, custom/external metrics, avoiding thrash with stabilization windows, and requests as the foundation underneath it all. Use this whenever the user is configuring an HPA, deciding between HPA and VPA, debugging autoscaling that flaps, or sizing a cluster autoscaler. For the requests/limits autoscaling depends on use `kubernetes-operations`; for cost tradeoffs use `cost-optimization`./backup-and-restoreDefines the discipline of building backups you can actually restore under pressure — RPO-driven frequency, restores rehearsed on a schedule, offsite immutable copies, encryption, and treating a backup that has never been restored as equivalent to no backup at all. Use this whenever the user sets up a backup job, chooses a retention policy, argues about RPO or RTO, asks whether current backups are enough, or plans for ransomware or accidental deletion. For the wider recovery plan use `disaster-recovery`, and for stateful platform durability use `stateful-workloads`.