Environment
- Deployment: Docker Compose, self-hosted on a VPS (added as an extra service alongside an existing
nousresearch/hermes-agent container, not using the bundled docker-compose.yml)
- Backend: existing hermes-agent gateway, OpenRouter provider, no Anthropic key configured
- Build: via the provided
Dockerfile
Problem 1: pnpm ignores native build scripts, breaks the build
Building the image with the Dockerfile's default pnpm install --no-frozen-lockfile fails with:
[ERR_PNPM_IGNORED_BUILDS] Ignored build scripts: better-sqlite3@12.8.0, esbuild@0.27.4, unrs-resolver@1.11.1 Run "pnpm approve-builds" to pick which dependencies should be allowed to run scripts.
followed by a hard failure (exit code 1) on the install step. This is pnpm 10+'s new default of refusing to auto-run postinstall/build scripts for packages like better-sqlite3 (a native module) unless explicitly approved. Since better-sqlite3 needs its native binary built to actually work, this isn't just a cosmetic warning — the app would likely be broken at runtime even if the build somehow succeeded.
Suggested fix: pin an older pnpm version, or add an explicit approval step before install:
dockerfile RUN npm install -g pnpm && pnpm approve-builds better-sqlite3 esbuild unrs-resolver && pnpm install --no-frozen-lockfile
Workaround used: switched the Dockerfile from pnpm install to npm install, which sidesteps this failure entirely.
Problem 2: Missing dependencies remark-math and rehype-katex
After working around Problem 1, the build still failed because remark-math and rehype-katex are used somewhere in the codebase (presumably for markdown math rendering) but aren't declared in package.json / the lockfile. Had to manually patch the Dockerfile to install them:
dockerfile RUN npm install remark-math rehype-katex
Suggested fix: add both packages to package.json dependencies and regenerate pnpm-lock.yaml.
Steps to reproduce
git clone the repo on a fresh Linux VPS
docker build using the provided Dockerfile (or docker compose build if added as a service)
- Build fails at the install step per Problem 1; after working around it, fails again per Problem 2
Suggested combined fix
- Regenerate the lockfile with
remark-math and rehype-katex included as explicit dependencies
- Either downgrade the pinned pnpm version in the Dockerfile, or add
pnpm approve-builds for the native-module packages before pnpm install, so a clean git clone → docker build works without manual Dockerfile edits
Environment
nousresearch/hermes-agentcontainer, not using the bundled docker-compose.yml)DockerfileProblem 1: pnpm ignores native build scripts, breaks the build
Building the image with the Dockerfile's default
pnpm install --no-frozen-lockfilefails with:
[ERR_PNPM_IGNORED_BUILDS] Ignored build scripts: better-sqlite3@12.8.0, esbuild@0.27.4, unrs-resolver@1.11.1 Run "pnpm approve-builds" to pick which dependencies should be allowed to run scripts. followed by a hard failure (exit code 1) on the install step. This is pnpm 10+'s new default of refusing to auto-run postinstall/build scripts for packages like
better-sqlite3(a native module) unless explicitly approved. Sincebetter-sqlite3needs its native binary built to actually work, this isn't just a cosmetic warning — the app would likely be broken at runtime even if the build somehow succeeded.Suggested fix: pin an older pnpm version, or add an explicit approval step before install:
dockerfile RUN npm install -g pnpm && pnpm approve-builds better-sqlite3 esbuild unrs-resolver && pnpm install --no-frozen-lockfile Workaround used: switched the Dockerfile from
pnpm installtonpm install, which sidesteps this failure entirely.Problem 2: Missing dependencies
remark-mathandrehype-katexAfter working around Problem 1, the build still failed because
remark-mathandrehype-katexare used somewhere in the codebase (presumably for markdown math rendering) but aren't declared inpackage.json/ the lockfile. Had to manually patch the Dockerfile to install them:
dockerfile RUN npm install remark-math rehype-katex Suggested fix: add both packages to
package.jsondependencies and regeneratepnpm-lock.yaml.Steps to reproduce
git clonethe repo on a fresh Linux VPSdocker buildusing the provided Dockerfile (ordocker compose buildif added as a service)Suggested combined fix
remark-mathandrehype-katexincluded as explicit dependenciespnpm approve-buildsfor the native-module packages beforepnpm install, so a cleangit clone→docker buildworks without manual Dockerfile edits