From devops-coding-agent
Reviews pipeline YAML and Dockerfiles against merged guidelines and org compliance requirements. Checks pipeline structure, stage ordering, runner configuration, scan stages, and Dockerfile security. Uses YAML LSP for syntax validation. Outputs structured findings with severity levels (blocker, suggestion, nit) and references to the specific guideline rule that was violated.
How this skill is triggered — by the user, by Claude, or both
Slash command
/devops-coding-agent:code-reviewThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Validates the full set of pipeline YAML and Dockerfile changes against the merged guidelines before the agent reports completion. Also available on-demand via the `/devops-review` command for reviewing existing pipelines not generated by the agent.
Validates the full set of pipeline YAML and Dockerfile changes against the merged guidelines before the agent reports completion. Also available on-demand via the /devops-review command for reviewing existing pipelines not generated by the agent.
Run these checks against every pipeline YAML file in scope (generated or existing).
build, dockerBuild, registryPush (or equivalent job names).dockerBuild/registryPush must depend on all upstream scan and test stages.needs: (GH Actions) or dependsOn: (ADO) references — all referenced job/stage names exist.runs-on (GH Actions) or pool (ADO) is set on every job/stage — no jobs missing a runner declaration.## Runner Config or ## Pool Config).self-hosted runners are required by org policy, no job uses a GitHub-hosted runner (e.g., ubuntu-latest) except where explicitly approved.uses: actions (GH Actions) are pinned to a major version tag or SHA — no unpinned @main, @master, or @latest references.Docker@2, SonarQubePrepare@6) are pinned to a major version number.${{ secrets.SECRET_NAME }} (GH Actions) or variable groups (ADO).env: blocks, variables: sections, or run: / script: steps.ACR_USERNAME, ACR_PASSWORD, SNYK_TOKEN, SONAR_TOKEN, etc.).package-lock.json, pom.xml, go.sum, requirements.txt) for deterministic cache invalidation.actions/cache@v4 or built-in setup action caching is used.Cache@2 task is used where caching is enabled in config.sonarScan.enabled is true in config, a SonarQube scan stage/job is present in the pipeline.fetch-depth: 0 (GH Actions actions/checkout) for full history analysis.snykScan.enabled is true, a Snyk scan stage/job is present.snyk/actions/dotnet@v1, snyk/actions/node@v1, etc.) not generic.wizScan.enabled is true, a Wiz CLI scan step is present in the docker-build-push job.azure/docker-login@v1 or Docker@2; ECR: aws-actions/amazon-ecr-login@v2 or AWSShellScript@1).latest alone.Run these checks against every Dockerfile in scope.
AS build and AS runtime stages minimum).COPY --from=build.addgroup -S appgroup && adduser -S appuser -G appgroup, or groupadd -r/useradd -r).USER directive is present in the runtime stage and set to the non-root user.USER directive is placed after all RUN installation steps but before ENTRYPOINT/CMD.USER nonroot:nonroot is set (UID 65532).ubuntu:latest, debian:latest) unless explicitly approved.latest.defaults.docker.baseImage is set in config, the runtime stage uses that image.package*.json, pom.xml, go.mod go.sum, requirements.txt) are copied before application source code.RUN commands that install packages are grouped into single layers where possible to reduce layer count.apt-get or apk add use --no-cache or apt-get clean && rm -rf /var/lib/apt/lists/* to minimize layer size.ENV, ARG, or RUN instruction.COPY does not reference .env files, credential files, or private keys.--mount=type=secret or are not persisted in final layers.HEALTHCHECK instruction is present in the runtime stage (exception: distroless images — documented absence is acceptable).--interval) and timeout (--timeout) are set to reasonable values.org.opencontainers.image.source) is present in the runtime stage.These checks apply across both pipeline YAML and Dockerfiles and verify adherence to org policy.
## section is checked independently.github-actions or azure-devops) is in governance.approvedPlatforms.acr or ecr) is in governance.approvedRegistries.dotnet, nodejs, java, golang, python) is in governance.approvedLanguages.## Forbidden section exists in merged guidelines, all listed forbidden patterns are absent from output files.latest tag in production registry push steps (flagged as blocker if org policy prohibits it).Before reporting review results, run LSP.getDiagnostics on all pipeline YAML files in scope.
| Phase | LSP Action |
|---|---|
| Before review analysis | LSP.getDiagnostics to establish baseline errors in existing files |
| After checklist review | LSP.getDiagnostics final pass on generated/modified files |
During /devops-review command | LSP.getDiagnostics on all files passed to the command |
LSP diagnostics surface YAML syntax errors and schema violations (workflow schema for GH Actions, Azure Pipelines schema for ADO) independently of the guideline checklist. LSP errors are always reported as blockers regardless of severity classification in guidelines.
If enforceLsp is true and the LSP is unavailable, the code review step halts with a blocking error rather than proceeding without LSP validation.
Each finding is reported with the following structure:
{
"severity": "blocker | suggestion | nit",
"file": "<relative file path>",
"line": "<line number or range, if determinable>",
"rule": "<exact quoted guideline text, including ## section heading>",
"message": "<description of the violation>",
"suggestion": "<recommended correction>",
"waived": false
}
Severity definitions:
| Severity | Meaning | Blocks completion |
|---|---|---|
blocker | Violates a mandatory guideline, org policy, security requirement, or LSP error | Yes — must be resolved before agent reports success |
suggestion | Violates a best-practice guideline in a non-mandatory section | No — surfaced for team awareness |
nit | Minor style or consistency issue, preference-level feedback | No — surfaced informally |
Summary output:
{
"reviewComplete": true,
"blockers": 0,
"suggestions": 2,
"nits": 1,
"lspErrors": 0,
"findings": [],
"guidelinesChecked": "merged-guidelines (6 sections, 2 layers applied)",
"filesReviewed": [
".github/workflows/ci.yml",
"Dockerfile"
]
}
When blockers is 0 and lspErrors is 0, the review passes and the agent may report completion. When blockers > 0 or lspErrors > 0, the agent must attempt to fix each blocking finding before re-running the review. Suggestions and nits are surfaced in the completion report but do not block.
Guides completion of development work by verifying tests, detecting environment, and presenting structured options for merge, PR, or cleanup.
Enforces test-driven development: write failing test first, then minimal code to pass. Use when implementing features or bugfixes.
Guides creation and editing of skills using test-driven development with pressure scenarios and subagents to verify agent compliance.
npx claudepluginhub gagandeepp/software-agent-teams --plugin devops-coding-agent