From 3d5ce1a4bb297cb01f9c3851ccaf014338f46eba Mon Sep 17 00:00:00 2001 From: Mikael Hugo Date: Mon, 18 May 2026 02:29:56 +0200 Subject: [PATCH] ci: skip web npm ci + build:web-host on alpine runner (docker does it) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The forgejo-runner pod is alpine/musl. npm pulls native bindings for the runner's detected libc, but lightningcss + @next/swc shipped variants mismatch (gnu installed, musl missing or vice versa) — Next.js build crashes with 'libc.musl-x86_64.so.1: cannot open shared object'. docker/Dockerfile.sf-server already runs both `npm --prefix web ci` (line 32) and `npm run build:web-host` (line 48) inside node:26.1-slim (glibc), so the runner copy is pure duplication anyway. Drop it. Image-build is the single source of truth for the shipped web/ bundle. Co-Authored-By: Claude Opus 4.7 (1M context) --- .forgejo/workflows/self-deploy.yml | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/.forgejo/workflows/self-deploy.yml b/.forgejo/workflows/self-deploy.yml index b7ef70602..2e5836e7e 100644 --- a/.forgejo/workflows/self-deploy.yml +++ b/.forgejo/workflows/self-deploy.yml @@ -43,21 +43,23 @@ jobs: # which is on PATH for all steps. package.json declares # engines: { node: ">=26.1.0" } for runtime, but build-time tsc + tests # work on Node 22 — we just need to opt out of npm's engine enforcement. - - name: Install dependencies + # We intentionally skip the `web` npm ci + `build:web-host` here. + # docker/Dockerfile.sf-server re-runs both inside a glibc-based + # node:26.1-slim image (lines 32 + 48). The runner is alpine/musl + # and npm picks the wrong native bindings (lightningcss / @next/swc), + # so duplicating the work here just breaks. Image-build is the + # source of truth for what ships to prod. + - name: Install dependencies (core only) env: NPM_CONFIG_ENGINE_STRICT: "false" run: | set -eu echo "node $(node --version) / npm $(npm --version)" npm ci --engine-strict=false - npm --prefix web ci --engine-strict=false - name: Build core run: npm run build:core - - name: Build web host - run: npm run build:web-host - - name: Typecheck extensions run: npm run typecheck:extensions