From c0aa7153c763735dd37209bbd88ced0c06ba5e81 Mon Sep 17 00:00:00 2001 From: Jean-Luc Makiola Date: Sun, 28 Jun 2026 13:52:15 +0200 Subject: [PATCH] Use npm install instead of npm ci in build Astro 7's wasm32 optional deps (@emnapi/*) make npm ci's strict lock-sync check fail across npm/node versions. npm install reconciles and builds. Co-Authored-By: Claude Opus 4.8 (1M context) --- Dockerfile | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/Dockerfile b/Dockerfile index d5a5220..859422b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,13 +4,11 @@ FROM node:22-slim AS build WORKDIR /app -# The lockfile is generated by npm 11; node:22 ships npm 10, which rejects it -# ("Missing: @emnapi/core ..."). Match the generator before installing. -RUN npm install -g npm@11 - -# Install deps against the lockfile for reproducible builds. +# Use npm install (not npm ci): Astro 7's wasm32 optional deps (@emnapi/*) +# make npm ci's strict lock-sync check fail across npm/node versions. install +# reconciles the lockfile and builds reliably. COPY package.json package-lock.json* ./ -RUN npm ci +RUN npm install --no-audit --no-fund COPY . . # PUBLIC_* env vars are inlined at build time. In Coolify, set them as