From cc86526f47742b68ee1539b2439903ced0caa8d9 Mon Sep 17 00:00:00 2001 From: Renovate Bot Date: Wed, 27 May 2026 00:41:34 +0000 Subject: [PATCH 1/6] chore(deps): update node docker tag to v26 --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 43076c7..f3fb581 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM node:24-trixie +FROM node:26-trixie ENV NPM_CONFIG_UPDATE_NOTIFIER=false \ NPM_CONFIG_LOGLEVEL=warn \ -- 2.52.0 From 6ccd634cd9fa8c4d3b7e1af52926b6ba5be7133f Mon Sep 17 00:00:00 2001 From: Hermes Agent Date: Mon, 13 Jul 2026 23:18:25 +0000 Subject: [PATCH 2/6] fix: upgrade better-sqlite3 to v12 for Node 26 compatibility n2-soul@9.0.9 depends on better-sqlite3@^11.10.0 which does not support Node.js 26. The V8 API changed (GetPrototype removed in favor of GetPrototypeV2), causing native compilation to fail. Upgrade to better-sqlite3@12.11.1 which supports Node 26 and has prebuilt binaries. --- Dockerfile | 1 + 1 file changed, 1 insertion(+) diff --git a/Dockerfile b/Dockerfile index f3fb581..77940c4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -13,6 +13,7 @@ RUN apt-get update && \ useradd -m -u 1000 -g 1000 -s /usr/bin/bash opencode; \ npm update -g --no-fund --no-audit && \ npm install -g --no-fund --no-audit --allow-scripts=opencode-ai,better-sqlite3 opencode-ai@1.17.18 n2-soul@9.0.9 && \ + cd /usr/local/lib/node_modules/n2-soul && npm install --no-fund --no-audit --no-save better-sqlite3@12.11.1 && cd / && \ npm cache clean --force && \ chown -R 1000:1000 /usr/local/lib/node_modules/n2-soul/ -- 2.52.0 From 25ce5423ed9635609470b2022d0e18088fe7f854 Mon Sep 17 00:00:00 2001 From: Hermes Agent Date: Mon, 13 Jul 2026 23:19:18 +0000 Subject: [PATCH 3/6] fix: use subshell to avoid hadolint DL3003 warning --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 77940c4..0d5f5db 100644 --- a/Dockerfile +++ b/Dockerfile @@ -13,7 +13,7 @@ RUN apt-get update && \ useradd -m -u 1000 -g 1000 -s /usr/bin/bash opencode; \ npm update -g --no-fund --no-audit && \ npm install -g --no-fund --no-audit --allow-scripts=opencode-ai,better-sqlite3 opencode-ai@1.17.18 n2-soul@9.0.9 && \ - cd /usr/local/lib/node_modules/n2-soul && npm install --no-fund --no-audit --no-save better-sqlite3@12.11.1 && cd / && \ + (cd /usr/local/lib/node_modules/n2-soul && npm install --no-fund --no-audit --no-save better-sqlite3@12.11.1) && \ npm cache clean --force && \ chown -R 1000:1000 /usr/local/lib/node_modules/n2-soul/ -- 2.52.0 From 523c39808feca1ccaefa99750663d4537514fcf1 Mon Sep 17 00:00:00 2001 From: Hermes Agent Date: Mon, 13 Jul 2026 23:21:19 +0000 Subject: [PATCH 4/6] fix: suppress hadolint DL3003 for subshell cd pattern --- Dockerfile | 1 + 1 file changed, 1 insertion(+) diff --git a/Dockerfile b/Dockerfile index 0d5f5db..183927f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,6 +4,7 @@ ENV NPM_CONFIG_UPDATE_NOTIFIER=false \ NPM_CONFIG_LOGLEVEL=warn \ NODE_ENV=production +# hadolint ignore=DL3003 RUN apt-get update && \ apt-get upgrade -y --no-install-recommends ca-certificates && \ rm -rf /var/lib/apt/lists/* && \ -- 2.52.0 From 988bf26667c21f434230b1a8904b2a2e5b34bb33 Mon Sep 17 00:00:00 2001 From: Hermes Agent Date: Mon, 13 Jul 2026 23:26:20 +0000 Subject: [PATCH 5/6] fix: install n2-soul with --ignore-scripts, then upgrade better-sqlite3 n2-soul's npm install fails on Node 26 because its dependency better-sqlite3@11.10.0 cannot compile (V8 API removed GetPrototype). The subsequent upgrade to v12 never runs due to set -eux. Fix: install n2-soul without scripts, then replace better-sqlite3 with v12.11.1 which has prebuilt binaries for Node 26. open-code-ai is installed separately with scripts allowed. --- Dockerfile | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 183927f..7ffa7de 100644 --- a/Dockerfile +++ b/Dockerfile @@ -13,8 +13,10 @@ RUN apt-get update && \ groupadd -g 1000 opencode; \ useradd -m -u 1000 -g 1000 -s /usr/bin/bash opencode; \ npm update -g --no-fund --no-audit && \ - npm install -g --no-fund --no-audit --allow-scripts=opencode-ai,better-sqlite3 opencode-ai@1.17.18 n2-soul@9.0.9 && \ - (cd /usr/local/lib/node_modules/n2-soul && npm install --no-fund --no-audit --no-save better-sqlite3@12.11.1) && \ + npm install -g --no-fund --no-audit --ignore-scripts n2-soul@9.0.9 && \ + rm -rf /usr/local/lib/node_modules/n2-soul/node_modules/better-sqlite3 && \ + (cd /usr/local/lib/node_modules/n2-soul && npm install --no-fund --no-audit --no-save --allow-scripts=better-sqlite3 better-sqlite3@12.11.1) && \ + npm install -g --no-fund --no-audit --allow-scripts=opencode-ai opencode-ai@1.17.18 && \ npm cache clean --force && \ chown -R 1000:1000 /usr/local/lib/node_modules/n2-soul/ -- 2.52.0 From 9cf881a8fd0340f1c34cf66b4095babaaaa24827 Mon Sep 17 00:00:00 2001 From: Hermes Agent Date: Mon, 13 Jul 2026 23:28:16 +0000 Subject: [PATCH 6/6] fix: install better-sqlite3 globally, remove local copy in n2-soul npm 10+ rejects --allow-scripts in project-scoped (non-global) installs. Install better-sqlite3@12.11.1 globally with --allow-scripts, then remove the incompatible v11.10.0 from n2-soul's node_modules so Node.js resolves the global v12.11.1 instead. --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 7ffa7de..5728d84 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,7 +4,7 @@ ENV NPM_CONFIG_UPDATE_NOTIFIER=false \ NPM_CONFIG_LOGLEVEL=warn \ NODE_ENV=production -# hadolint ignore=DL3003 + RUN apt-get update && \ apt-get upgrade -y --no-install-recommends ca-certificates && \ rm -rf /var/lib/apt/lists/* && \ @@ -14,8 +14,8 @@ RUN apt-get update && \ useradd -m -u 1000 -g 1000 -s /usr/bin/bash opencode; \ npm update -g --no-fund --no-audit && \ npm install -g --no-fund --no-audit --ignore-scripts n2-soul@9.0.9 && \ + npm install -g --no-fund --no-audit --allow-scripts=better-sqlite3 better-sqlite3@12.11.1 && \ rm -rf /usr/local/lib/node_modules/n2-soul/node_modules/better-sqlite3 && \ - (cd /usr/local/lib/node_modules/n2-soul && npm install --no-fund --no-audit --no-save --allow-scripts=better-sqlite3 better-sqlite3@12.11.1) && \ npm install -g --no-fund --no-audit --allow-scripts=opencode-ai opencode-ai@1.17.18 && \ npm cache clean --force && \ chown -R 1000:1000 /usr/local/lib/node_modules/n2-soul/ -- 2.52.0