Skip to content

Exclude local secrets and artifacts from Docker contexts - #41

Merged
jhl-hk merged 2 commits into
mainfrom
fix/docker-context-exclusions
Nov 10, 2026
Merged

jhl-hk merged 2 commits into
mainfrom
fix/docker-context-exclusions

Conversation

@jhl-hk

@jhl-hk jhl-hk commented Nov 10, 2026

Copy link
Copy Markdown
Contributor

Changes

  • Add .dockerignore excluding root and nested .env* files, dependencies, build outputs, VCS metadata, scratch directories and licensed navdata.
  • Keep package manifests, .npmrc, source, assets, build configuration and other data in the build context.
  • Document the Docker context rules.

Verification

  • Checked the rules with the Moby pattern matcher used by Docker (v0.6.1), including root and nested paths.
  • Prettier passes on the documentation.
  • No image build was run.

Part of JianyueLab/can-web#177

@github-actions

github-actions Bot commented Nov 10, 2026 •

Copy link
Copy Markdown

🤖 AI Code Review

Incremental review of 7ab8902..74a2ab1. Earlier findings stay as inline comments.

🔴 0 critical · 🟠 0 warning · 🔵 0 suggestion

The changes correctly remove host .npmrc and environment files from the Docker context while generating registry configuration inside the build stage. The BuildKit secret is scoped to dependency installation and the generated configuration is not copied into the runtime image. I found no concrete bugs or security issues in the shown changes.

No issues found.

Model: expen · generated automatically. Use judgment — it can be wrong.

@jhl-hk
jhl-hk merged commit 08a59aa into main Nov 10, 2026
2 checks passed
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.

1 participant