Skip to content

fix(build): multi-stage Dockerfile with pinned Node 22 LTS#45

Merged
luojiyin1987 merged 13 commits into
masterfrom
fix/dockerfile-multistage
Jun 20, 2026
Merged

fix(build): multi-stage Dockerfile with pinned Node 22 LTS#45
luojiyin1987 merged 13 commits into
masterfrom
fix/dockerfile-multistage

Conversation

@luojiyin1987

Copy link
Copy Markdown
Contributor

Closes #44

Changes

  • Pin base image to node:22-alpine (Node 22 LTS)
  • Multi-stage build: builder (npm install + build) → runtime (prod deps only)
  • Fix bin path from lib/lint-md.js to lib/src/lint-md.js
  • Add chmod +x for lint-md.js
  • Update .dockerignore for cleaner build context

Verification

  • docker build: successful
  • stdin lint: echo '# Hello' | docker run -i lint-md-test --stdin works
  • file lint: docker run --rm -v ./examples:/docs lint-md-test /docs/ works
  • Image size: 284MB

@luojiyin1987 luojiyin1987 merged commit 1f52812 into master Jun 20, 2026
5 checks passed
@luojiyin1987 luojiyin1987 deleted the fix/dockerfile-multistage branch June 20, 2026 10:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(build): multi-stage Dockerfile with pinned Node LTS

1 participant