From 9b727abe4d78dbc3eae4bd655fcd6be536552eab Mon Sep 17 00:00:00 2001 From: Meta Vens Date: Sun, 6 Sep 2026 16:43:10 +0200 Subject: [PATCH] Run pnpm through corepack in the build runner The pinned node image provides npm but not pnpm, and the image entrypoint execs node for an unrecognised first argument, so a pnpm step failed with "Cannot find module /workspace/pnpm". Heimdall declares packageManager: pnpm@10.33.0, and corepack ships with node and honours that declaration, so it is the toolchain the image already has rather than a second thing to install. corepack needs a writable home; COREPACK_HOME joins the step environment alongside NPM_CONFIG_CACHE and HOME, pointing into the bind-mounted cache. Co-Authored-By: Claude Opus 5 --- deployment/idunn/recipe.toml | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/deployment/idunn/recipe.toml b/deployment/idunn/recipe.toml index e9a0d8d..ce908d4 100644 --- a/deployment/idunn/recipe.toml +++ b/deployment/idunn/recipe.toml @@ -33,50 +33,50 @@ required_gitlinks = ["vendor/CultLib"] id = "install-cultlib" phase = "build" runner = "node-build" -required_environment = ["NPM_CONFIG_CACHE", "HOME"] +required_environment = ["NPM_CONFIG_CACHE", "HOME", "COREPACK_HOME"] argv = ["npm", "ci", "--ignore-scripts", "--prefix", "vendor/CultLib"] [[steps]] id = "build-cultcache-ts" phase = "build" runner = "node-build" -required_environment = ["NPM_CONFIG_CACHE", "HOME"] +required_environment = ["NPM_CONFIG_CACHE", "HOME", "COREPACK_HOME"] argv = ["npm", "run", "build", "--prefix", "vendor/CultLib", "--workspace=cultcache-ts"] [[steps]] id = "build-cultnet-ts" phase = "build" runner = "node-build" -required_environment = ["NPM_CONFIG_CACHE", "HOME"] +required_environment = ["NPM_CONFIG_CACHE", "HOME", "COREPACK_HOME"] argv = ["npm", "run", "build", "--prefix", "vendor/CultLib", "--workspace=cultnet-ts"] [[steps]] id = "build-cultmesh-ts" phase = "build" runner = "node-build" -required_environment = ["NPM_CONFIG_CACHE", "HOME"] +required_environment = ["NPM_CONFIG_CACHE", "HOME", "COREPACK_HOME"] argv = ["npm", "run", "build", "--prefix", "vendor/CultLib", "--workspace=cultmesh-ts"] [[steps]] id = "install-heimdall" phase = "build" runner = "node-build" -required_environment = ["NPM_CONFIG_CACHE", "HOME"] -argv = ["pnpm", "install", "--frozen-lockfile"] +required_environment = ["NPM_CONFIG_CACHE", "HOME", "COREPACK_HOME"] +argv = ["corepack", "pnpm", "install", "--frozen-lockfile"] [[steps]] id = "test-heimdall" phase = "test" runner = "node-build" -required_environment = ["NPM_CONFIG_CACHE", "HOME"] -argv = ["pnpm", "test"] +required_environment = ["NPM_CONFIG_CACHE", "HOME", "COREPACK_HOME"] +argv = ["corepack", "pnpm", "test"] [[steps]] id = "build-heimdall" phase = "build" runner = "node-build" -required_environment = ["NPM_CONFIG_CACHE", "HOME"] -argv = ["pnpm", "build"] +required_environment = ["NPM_CONFIG_CACHE", "HOME", "COREPACK_HOME"] +argv = ["corepack", "pnpm", "build"] # The unit runs dist/src/index.js, and Node resolves its imports at runtime, so # the release is the compiled output plus the production dependency tree. These