fix(n8n): disable pnpm minimumReleaseAge check for offline prune
n8n >= 2.45 sets `minimumReleaseAge: 2880` in pnpm-workspace.yaml. pnpm 12 enforces that supply-chain policy on `pnpm prune --prod` (preInstall) by fetching registry metadata for every lockfile entry, which hangs the build in the network-less sandbox. Disable the check for prune and force --offline so future registry access fails fast instead of stalling. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
1c46b2bcc5
commit
4a047cb3be
1 file changed
+14
@@ -69,6 +69,20 @@ in
|
|||||||
else x)
|
else x)
|
||||||
previousAttrs.nativeBuildInputs;
|
previousAttrs.nativeBuildInputs;
|
||||||
|
|
||||||
|
# Upstream preInstall runs `pnpm prune --prod`. n8n >= 2.45 sets
|
||||||
|
# `minimumReleaseAge: 2880` in pnpm-workspace.yaml, and pnpm 12 enforces
|
||||||
|
# that supply-chain policy on prune by fetching registry metadata for every
|
||||||
|
# lockfile entry. In the network-less sandbox that stalls the build
|
||||||
|
# indefinitely right after "Removing non-deterministic and unnecessary
|
||||||
|
# files". The lockfile is fixed by pnpmDeps' hash anyway, so disable the
|
||||||
|
# check for prune and force --offline so any future registry access fails
|
||||||
|
# fast instead of hanging.
|
||||||
|
preInstall =
|
||||||
|
builtins.replaceStrings
|
||||||
|
["CI=true pnpm --ignore-scripts prune --prod -w"]
|
||||||
|
["CI=true pnpm --ignore-scripts --offline --config.minimum-release-age=0 prune --prod -w"]
|
||||||
|
previousAttrs.preInstall;
|
||||||
|
|
||||||
preBuild =
|
preBuild =
|
||||||
(previousAttrs.preBuild or "")
|
(previousAttrs.preBuild or "")
|
||||||
+ ''
|
+ ''
|
||||||
|
|||||||
Reference in new issue
Block a user