fix(deploy): move onlyBuiltDependencies to pnpm-workspace.yaml

pnpm 10+ no longer reads pnpm.onlyBuiltDependencies from package.json and
blocks build scripts by default, so better-sqlite3's native binary was
never compiled on install (ERR_PNPM_IGNORED_BUILDS) — the SSR server would
crash at runtime. Allow-list the native/build-script deps here so every
`pnpm install` (including scripts/deploy.sh) builds them.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
Arlind 2026-06-17 14:40:29 +02:00
parent d27ab4c98b
commit cf534777af

9
pnpm-workspace.yaml Normal file
View file

@ -0,0 +1,9 @@
# pnpm 10+ moved several settings out of package.json's "pnpm" field into
# this file. `onlyBuiltDependencies` allow-lists packages permitted to run
# install/build scripts (pnpm now blocks build scripts by default). Without
# this, better-sqlite3's native binary is never compiled and the server
# crashes at runtime with ERR_DLOPEN_FAILED / NODE_MODULE_VERSION mismatch.
onlyBuiltDependencies:
- better-sqlite3
- esbuild
- sharp