Reviews infrastructure code or design docs against OKF k8s/Terraform bundle, returning severity-ranked findings on ownership overlap, image digest continuity, and secret exposure. Includes multi-cloud and environment-parity sections.
Ships in infra. 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.
A review a team can act on: an ownership map, findings ranked by severity, each written as path:line → what → impact → fix → source, plus a mandatory multi-cloud section and a mandatory environment-parity section — and the things that genuinely cannot be judged from outside listed as open questions rather than guessed at.
| Situation | Do this |
|---|---|
| The environment is unknown | Ask before writing findings. The same code gets a different verdict per environment (§ Per-Environment Standards) |
The finding concerns local or production | Both are outside the observed implementation. Ground the finding in this skill's conventions or in official documentation — never in the bundle's authority |
| The repository and the bundle differ | The repository is what exists. The bundle is a snapshot of specific commits; do not assert "it should look like this" without reading the code |
| The topic is outside the bundle | Say so, then WebFetch official documentation or record it as an open question |
| A finding has no proposed fix | It is not finished. Do not emit findings without fixes |
| File | Required/Recommended | Source |
|---|---|---|
knowledge/okf-k8s-tf/ | Required | Vendored bundle (@rules/okf-k8s-tf-bundle.md) |
| The review target (repository / MR diff / design document, with revision) | Required | The user |
| Previous round's review report | Recommended | $OUT/reviews/review-<target>-r<n-1>.md |
When invoked from /infra:start, environment, cloud, target path and $OKF arrive already
settled. Do not re-ask them.
templates/infra/review-report.md.--round=<n> says
otherwise.Check these in order; anything found here is written before every other finding.
Walk every item of architecture/design-build-checklist.md. Below is that list plus the points
worth digging into.
fmt / validate / plan / static analysis; apply restricted to protected refs-target not baked into normal operationcluster-admin, wildcard verbs/resources, default ServiceAccount tokensmain / latest)ClusterSecretStore not shared without restrictiondataFrom / templates not copying broad value sets into Kubernetes Secretskyverno.io/v1 ClusterPolicy still in use? (see Known Patterns — the most important
known issue)Against @rules/infra/multi-cloud.md.
Against @rules/infra/environments.md §6. The eleven checks there are used verbatim.
The same code gets a different verdict in a different environment. Never write a finding without confirming the environment.
This table is this skill's convention — the bundle has no per-environment verdict table. Rows that do have bundle grounds carry their own source (direct apply being deliberate in test [architecture/platform-architecture.md], the staged Kyverno Audit → Enforce rollout [security/kyverno.md], Vault HA as a production requirement [secrets/vault.md]). When using this table in a finding, speak with the bundle's authority only for those rows.
| Aspect | local | test | staging | production |
|---|---|---|---|---|
| Replica 1 / no HA | acceptable | acceptable | check | NG |
| No signature verification / Kyverno | acceptable (state the limits) | Audit is fine | fine if mid-migration to Enforce | NG |
| Observability stack omitted | acceptable | partially | production-equivalent preferred | NG |
| Self-signed TLS | acceptable | check | NG | NG |
| Direct apply to the cluster | acceptable | deliberate design | NG (GitOps) | NG |
| Drift present | acceptable | expected (needs a re-creation procedure) | should be resolved by selfHeal | NG |
| Deploy without approval | acceptable | acceptable | MR merge is fine | NG |
| Production data present | NG | NG | masking mandatory | — |
| Plaintext secrets in Git | NG | NG | NG | NG |
| Environment branching in the base | NG | NG | NG | NG |
| Per-environment image rebuild | NG | NG | NG | NG |
The bottom four rows admit no exception in any environment. "It's only local" is not a reason (@rules/infra/environments.md §5).
Severity moves with the environment: as a rule drop one step going production > staging > test > local — except for the four rows above that are NG everywhere, whose severity never drops.
| Severity | Definition | Examples |
|---|---|---|
| Critical | Directly implies secret disclosure, data loss or a full outage | Plaintext secret in Git, unprotected shared state, a backup whose restore was never verified, production data reaching a lower environment |
| High | A realistic path to a production incident or a security breach | Ownership overlap, broken digest continuity, Cosign verify without an identity, surviving ClusterPolicy |
| Medium | Breeding ground for operational load and change accidents | Unpinned versions, a security gate allowed to fail, unmanaged label cardinality |
| Low | Readability, consistency, future improvement | Module naming, missing descriptions, duplicated overlays |
| Info | Not enough information; needs confirmation | Environment-dependent items that cannot be judged from outside |
Every finding is written as path:line → what → impact → fix → source bundle document. Never write a finding that only says something is bad.
| Pattern | What |
|---|---|
| Kyverno ClusterPolicy | kyverno.io/v1 ClusterPolicy is deprecated (critical fixes only). v1.18 stabilized ValidatingPolicy / MutatingPolicy / GeneratingPolicy / ImageValidatingPolicy under policies.kyverno.io/v1; v1.20 (planned for October 2026) removes the old one [security/kyverno.md]. The observed implementation still used ClusterPolicy; the migration procedure is in the same document |
| Pinning a major image tag | A tag like docker:27 is not pinned to a patch or digest. The bundle itself lists this as an improvement candidate [delivery/docker-cosign.md] |
| Re-resolving the digest after build | Re-resolving from a tag can shift what is scanned, signed and deployed. Capture the digest as an artifact right after build [delivery/docker-cosign.md] |
| No SBOM / provenance | Associating an SBOM and build provenance with the same digest is an open improvement [delivery/docker-cosign.md] |
| Moving CI template references | main / latest change behaviour without notice [delivery/gitlab-cicd.md] |
| Misreading PolicyReport | A PolicyReport is the current evaluation result, not a history of rejections. Investigating a blocked admission needs Events, metrics or audit logs [security/kyverno.md] |
Misreading the Orphan deletion policy | It leaves the Secret behind on deletion; it does not prevent overwrite on re-creation [secrets/external-secrets.md] |
| Misreading Vault HA | HA is for availability, not horizontal performance [secrets/vault.md] |
| Ad-hoc Argo CD rollback | Auto-sync re-applies the new revision. Rollback means Git revert or forward-fix [delivery/argocd.md] |
| Sync succeeded ≠ ready | Without a health assessment for a custom resource, do not conflate sync success with service readiness [delivery/argocd.md] |
| Production is not in the bundle | The ownership table has no production row and every mention is guidance. There is no such thing as "a production configuration as the bundle prescribes". Report production's apply path, approval and rollback as decisions still to be made (@rules/infra/environments.md §0) |
| Local is not in the bundle | Not covered at all. Ground findings about local configuration in this skill's conventions or official documentation, never in the bundle's authority |
| The test/staging asymmetry | Direct apply vs. GitOps is a deliberate design [architecture/platform-architecture.md]. Do not report the asymmetry itself. What is worth reporting is that the asymmetry is undocumented, and that test lacks a drift re-creation procedure |
| Staging drifting from production | The more they differ, the less staging proves. A difference with no stated reason is a finding |
| Flag | Effect |
|---|---|
--env=<env> | Target environment: local / test / staging / production. Repeatable |
--cloud=<cloud> | Target cloud: aws / azure / gcp. Repeatable |
--round=<n> | Force the review round number instead of deriving it from existing reports |
| File | Content |
|---|---|
$OUT/reviews/review-<target>-r<round>.md | The review report (templates/infra/review-report.md) |
Written in the project's options.output_language. Location per /infra:start
§ Output Location.
| Skill | Relationship |
|---|---|
| /infra:design, /infra:implement | Produce what this reviews |
| /architect:review-operations | Sibling — reviews operational readiness in design documents; this one reviews infrastructure code |
| gitlab-review | For turning an MR review into a write-up in the GitLab review convention |
What SKILL.md sets; muted values are Claude Code's defaults
opusThree short reads, in order
/infra:reviewfrom infra
npx claudepluginhub ryuking1228/ai-dev-codex-version --plugin infra4 skills in this plugin
/designInfrastructure DesignDesign a multi-cloud, four-environment infrastructure configuration from requirements and emit
the design document, environment matrix and ADRs. Grounded in the OKF k8s/tf bundle; writes no
implementation code.
/infra:design [target] [--env=<env>] [--cloud=<cloud>] [--auto] to invoke.
Use for "design the infrastructure", "decide the configuration", "select the technology",
"compare the approaches". Implementation follows separately via /infra:implement, after the
design is agreed.
/implementInfrastructure ImplementationWrite Terraform, Kubernetes manifests, Helm values, Kustomize overlays and CI definitions from
an agreed infrastructure design, into a real infrastructure repository. Enforces pinned
versions, single ownership, digest continuity and no secret exposure.
/infra:implement [target] [--env=<env>] [--cloud=<cloud>] [--auto] to invoke.
Use for "write the Terraform", "create the manifests", "implement the CI". For IaC scaffolding
emitted into generated/ as a pipeline codegen step, use /architect:generate-infra-code instead.
/startInfrastructure Triage and RoutingTriage entry point for multi-cloud (AWS / Azure / GCP) x four-environment
(local / test / staging / production) infrastructure work: resolves the OKF k8s/tf knowledge
bundle, checks its freshness, fixes the target environment and cloud, then routes to the
design, implement or review skill.
/infra:start [target] [--env=<env>] [--cloud=<cloud>] to invoke.
Use for "design the infrastructure", "write the Terraform", "review this IaC" and anything
that does not yet name a mode. Not for application domain design (/architect:*), ScalarDB
data modeling (/scalardb:*), or GitLab MR review write-ups (gitlab-review).
Other plugins' skills for the same job