



















@@ -92,7 +92,9 @@ describe("Dockerfile", () => {
9292it("uses the Docker target platform for pnpm install and prune", async () => {
9393const dockerfile = await readFile(dockerfilePath, "utf8");
9494const installIndex = dockerfile.indexOf("pnpm install --frozen-lockfile \\");
95-const storeAddIndex = dockerfile.indexOf("pnpm store add source-map@0.6.1");
95+const storeAddIndex = dockerfile.indexOf(
96+"pnpm list --prod --depth Infinity --json | node scripts/list-prod-store-packages.mjs | xargs -r pnpm store add",
97+);
9698const pruneIndex = dockerfile.indexOf("CI=true pnpm prune --prod \\");
979998100expect(installIndex).toBeGreaterThan(-1);
@@ -184,9 +186,7 @@ describe("Dockerfile", () => {
184186'OPENCLAW_EXTENSIONS="$OPENCLAW_EXTENSIONS" OPENCLAW_BUNDLED_PLUGIN_DIR="$OPENCLAW_BUNDLED_PLUGIN_DIR" node scripts/prune-docker-plugin-dist.mjs',
185187);
186188expect(dockerfile).toContain("CI=true pnpm prune --prod \\");
187-expect(
188-dockerfile.indexOf("CI=true pnpm prune --prod \\"),
189-).toBeLessThan(
189+expect(dockerfile.indexOf("CI=true pnpm prune --prod \\")).toBeLessThan(
190190dockerfile.indexOf(
191191'OPENCLAW_EXTENSIONS="$OPENCLAW_EXTENSIONS" OPENCLAW_BUNDLED_PLUGIN_DIR="$OPENCLAW_BUNDLED_PLUGIN_DIR" node scripts/prune-docker-plugin-dist.mjs',
192192),
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。