docs: document fail-fast lint stage pattern for Dockerfiles #18

Open
clawbot wants to merge 1 commits from update-dockerfile-lint-stage-docs into main
Collaborator

Documents the multistage Docker build pattern we now use across repos (chat, pixa, etc.) where a separate lint stage runs make fmt-check and make lint independently from the build stage.

Key additions to REPO_POLICIES.md:

  • Full Dockerfile template showing the lint → build → runtime stage pattern
  • Explanation of COPY --from=lint /src/go.sum /dev/null as the BuildKit dependency trick
  • Handling //go:embed placeholders in the lint stage
  • CGO/system library notes for the lint stage
  • Clarification that tests run in the build stage, not the lint stage

Reference implementations: sneak/chat, sneak/pixa.

Documents the multistage Docker build pattern we now use across repos (chat, pixa, etc.) where a separate `lint` stage runs `make fmt-check` and `make lint` independently from the build stage. Key additions to REPO_POLICIES.md: - Full Dockerfile template showing the lint → build → runtime stage pattern - Explanation of `COPY --from=lint /src/go.sum /dev/null` as the BuildKit dependency trick - Handling `//go:embed` placeholders in the lint stage - CGO/system library notes for the lint stage - Clarification that tests run in the build stage, not the lint stage Reference implementations: `sneak/chat`, `sneak/pixa`.
clawbot added 1 commit 2026-03-13 00:44:56 +01:00
docs: document fail-fast lint stage pattern for Dockerfiles
All checks were successful
check / check (push) Successful in 8s
3ec7ecfca8
Adds detailed documentation of the multistage Docker build pattern
where a separate lint stage runs fmt-check and lint before the build
stage begins. Includes the standard Dockerfile template, the BuildKit
dependency trick (COPY --from=lint), go:embed placeholder handling,
and CGO/system library notes.
All checks were successful
check / check (push) Successful in 8s
Required
Details
This pull request can be merged automatically.
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin update-dockerfile-lint-stage-docs:update-dockerfile-lint-stage-docs
git checkout update-dockerfile-lint-stage-docs
Sign in to join this conversation.
No Reviewers
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: sneak/prompts#18