Code & Engineering

Dockerfile Review

Reviews ONE Dockerfile for the five build mistakes that cost security or build time, and lists only those, one line each with a fixed code, the instruction, why it hurts and the fix - or exactly No findings. It catches a final image that runs as root, a base image with no tag or the latest tag, a secret passed through an argument, an environment value or a file copy so that it stays in the image history, source copied in before the dependencies are installed so the cache is lost on every edit, and the package index left in the layer after apt-get. It leaves out the safe look-alikes, such as a build secret mounted for one instruction, a tag pinned by digest, and root in a build stage that never ships. Use to review a Dockerfile before merging, to audit the images of a repository, or to speed up a slow image build.

Dockerfile Review is a tested SKILL.md that reviews ONE Dockerfile for the five build mistakes that cost security or build time, and lists only those, one line each with a fixed code, the instruction, why it hurts and the fix - or exactly No findings; an agent buys it once for $0.01 over x402.

Tested 2026-10-19No code, no hidden instructionsv1.0.0 · 6.1 KB · perpetual license

Not for

Image size, vulnerability scanning, health checks, signal handling, compose files and the contents of a dockerignore file. It reads one pasted Dockerfile and judges only what is written in it.

Tested, honestly

Tested 2026-10-19 with a strong and a weak model.

SonnetStrong model, claude-sonnet-5-5
Right on all 3 cases, read by hand. On the Go service it found the source copied before the module download and the final base with no tag, and left out the digest-pinned builder and the builder running as root. On the Python image it gave the missing user, the token argument and the apt lists, and left out the build secret mount. On the clean Node image it answered exactly No findings.
HaikuWeak model, claude-haiku-5-5
Right on all 3 cases, read by hand. It matched the strong model on both planted files, with sound fixes, and kept the secret mount and the digest-pinned builder out. On the clean image it answered exactly No findings. Its Python answer was indented by four spaces, which the check accepts.

Full test summary

Example

Our own test text, before and after the skill ran. Excerpts only.

English · claude-sonnet-5-5

Before

FROM golang:1.23@sha256:0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef AS build WORKDIR /src COPY . . RUN go mod download RUN CGO_ENABLED=0 go build -o /out/server ./cmd/server FROM alpine RUN adduser -D -u 10001 app COPY --from=build /out/server /usr/local/bin/server USER app ENTRYPOINT ["/usr/local/bin/server"]

After

UNPINNED-BASE — final stage `FROM alpine` — no tag, so the shipped base image changes under the same line — pin a version tag (for example `alpine:3.20`), optionally with a digest CACHE-ORDER — build stage `COPY . .` before `RUN go mod download` — every source edit repeats the module download — copy `go.mod` and `go.sum`, run `go mod download`, then copy the source

What is in the file

  • What the Docker documentation says, as published on 19 October 2026
  • The answer
  • The codes
  • Rules
  • Work in this order
  • Short example

Languages

English. Tried in: English.

License

Perpetual, non-exclusive; use and modify for yourself incl. paid work; no resale or republishing. Holder: Georgi Kalchev, aiskills402.com. Full terms.

Versions

Current version 1.0.0, updated 2026-10-19. Whoever bought an earlier version gets new ones free through the same re-download token.

  1. v1.0.0 · 2026-10-19

    First release, written in the light-test batch of 19 October 2026 (three cases, price $0.01). The idea is ours; no foreign skill was opened, facts come from public documentation (see notes/ideas.md). Output: see the skill description.

    Test: three cases written by hand (two planted, each with a safe look-alike, one clean control), one run on Claude Sonnet and one on Claude Haiku, no run without the skill, no iteration on the skill rules after the runs. One wording change after the runs: the reason on the first line of the short example was reworded, because a tested answer repeated it word for word and that answer is the public example; the rules and codes are unchanged. `test/control.mjs` shows that the checks pass on the ideal answers and fail on realistic wrong ones. See `test-summary.json` for the verdicts read by hand.

FAQ

Fixed version tag on the base image: flagged or not?

No. The skill states its policy: a fixed version tag is accepted, with or without a digest, and only a missing tag or the word latest is reported. A digest is described as the stronger form, as the Docker page says.

Is root in a build stage reported?

No. Only the stage that ships matters. A builder stage without a USER line is left alone, and so is a build secret mounted for a single instruction. An argument or an environment value that holds a token is reported.

Which Dockerfiles went into the test?

Three files: a Go service that copies its source before the module download and ships on a base with no tag, a Python image that takes a token as an argument, keeps the apt lists and has no user, and a clean two-stage Node image. Each file went to Claude Sonnet one time and to Claude Haiku one time, and on reading the answers both models met each expectation.

What does a clean Dockerfile return?

The sentence No findings. alone. A defect is one line with a code, the instruction, why it hurts and the fix; nothing is said about what was checked and found fine.

Share

Read this page as Markdown: /skills/dockerfile-review.md.

More in Code & Engineering

  • CodeTour File Builder

    Code & Engineering

    SKILL.md · v1.0.0 · 5.2 KB

    Turns a code tour described in words, plus the list of files with their line counts, into one valid CodeTour file (JSON with a title and steps, each step holding a file, a line and a description) and nothing else. It keeps file paths relative and exactly as listed, checks every line number against the length of its file, and leaves out a step whose file is not in the list or whose line lies past the end, naming each skipped step in the description of the tour in one fixed form. A tour with only valid steps carries no mention of skipping. Use to turn a walkthrough of a code base into a tour file for the CodeTour editor extension, to draft onboarding tours, or to rebuild a tour after files were renamed.

    $0.01once

    • x402
    • USDC
    • Base
    Get skill

    Tested with Sonnet and Haiku, 19 Oct 2026

  • HTML Email Compatibility Review

    Code & Engineering

    SKILL.md · v1.0.0 · 7.4 KB

    Reviews ONE HTML email (the source of a newsletter, a receipt or a notice) for the four mistakes that make it fall apart in common mail clients, and lists only those, one line each with a fixed code, the place, which client breaks it and the fix - or exactly No findings. It catches flex or grid used to lay out columns, layout rules that exist only in a style block in the head, images with no alt attribute, and a CSS background image with no colour fallback behind the text. It leaves out the safe look-alikes, such as a style block used only for media queries and an empty alt on a decorative spacer. Use before an email goes to a sending tool, to audit a template someone else built, or to find out why a message looks broken in Outlook for Windows or in a webmail that strips styles.

    $0.01once

    • x402
    • USDC
    • Base
    Get skill

    Tested with Sonnet and Haiku, 19 Oct 2026

  • Stripe Webhook Review

    Code & Engineering

    SKILL.md · v1.0.0 · 8.0 KB

    Reviews ONE Stripe webhook handler (the route code, in any language or framework) for the five mistakes that let a forged or repeated event move money, grant access or ship goods, and lists only those, one line each with a fixed code, the place, why it is dangerous and the fix - or exactly No findings. It catches a body parsed or re-serialized before the signature is checked, a handler that never checks the signature, a recency tolerance switched off or set huge, no record of event ids so a retry repeats the side effect, and slow work done before the 2xx answer. It leaves out the safe look-alikes, such as a raw body kept on the webhook route while the other routes parse JSON, and the default tolerance. Use to review a webhook route before going live, to audit one that someone else wrote, or to find out why signature checks fail or orders are fulfilled twice.

    $0.01once

    • x402
    • USDC
    • Base
    Get skill

    Tested with Sonnet and Haiku, 19 Oct 2026

  • GitHub Actions Security Review

    Code & Engineering

    SKILL.md · v1.0.0 · 8.3 KB

    Reviews ONE GitHub Actions workflow file (YAML) for the five mistakes that let an outsider run code or read secrets in your pipeline, and lists only those, one line each with a fixed code, the place, why it is dangerous and the fix - or exactly No findings. It catches text from an issue, pull request, comment or branch name pasted straight into a shell step, a pull_request_target or workflow_run job that checks out and runs the code of the pull request, a third-party action pinned to a tag or branch instead of a full commit hash, a missing or too wide permissions block, and a secret that is printed or handed to code you do not control. It leaves out the safe look-alikes, such as untrusted text passed through an env variable and quoted, or first-party actions pinned to a version tag. Use to review a workflow before merging it, to audit the pipelines of a repository, or to gate a pull request that edits a workflow file.

    $0.01once

    • x402
    • USDC
    • Base
    Get skill

    Tested with Sonnet and Haiku, 19 Oct 2026