fix(docker): include pnpm-workspace and npmrc in builder context
CI / check (push) Successful in 1m12s
CI / deploy (push) Successful in 1m26s

The committed lockfile records overrides from pnpm-workspace.yaml. With the
narrower manifest COPY, pnpm install --frozen-lockfile ran without the
workspace file and failed with ERR_PNPM_LOCKFILE_CONFIG_MISMATCH in CI.
Copy package.json, pnpm-lock, pnpm-workspace and .npmrc together so the
override config present in the lockfile is also supplied at install time.
This commit is contained in:
openhands committed 2026-09-07 11:33:04 +02:00
1 parent bef1775dea
commit 3e0ba73d1c
2 files changed
+5 -2

No files matched your search

+1 -1
View File
@@ -6,7 +6,7 @@ const dockerfile = readFileSync("Dockerfile", "utf8");
describe("Docker build cache", () => {
it("installs frozen dependencies before copying application source", () => {
const manifests = dockerfile.indexOf(
"COPY package.json pnpm-lock.yaml* ./",
"COPY package.json pnpm-lock.yaml* pnpm-workspace.yaml* .npmrc* ./",
);
const fetch = dockerfile.indexOf("pnpm fetch --ignore-scripts");
const install = dockerfile.indexOf("pnpm install --frozen-lockfile");