From 3b7e1d0ed911a6e513038c53e2f31d3c4644af11 Mon Sep 17 00:00:00 2001 From: Matthias Hochmeister Date: Sun, 1 Mar 2026 12:14:38 +0100 Subject: [PATCH] add now features --- sync/Dockerfile | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/sync/Dockerfile b/sync/Dockerfile index 4add938..d120c26 100644 --- a/sync/Dockerfile +++ b/sync/Dockerfile @@ -1,18 +1,17 @@ -# Stage 1: build TypeScript +# Stage 1: build TypeScript + install all deps FROM node:20-slim AS builder WORKDIR /app COPY package*.json ./ RUN npm ci --include=dev COPY tsconfig.json ./ COPY src ./src -RUN npm run build +RUN npm run build && npm prune --production -# Stage 2: runtime with Playwright +# Stage 2: runtime with Playwright — copy built artifacts, no npm install FROM mcr.microsoft.com/playwright:v1.47.0-jammy WORKDIR /app -COPY package*.json ./ -RUN npm ci --omit=dev RUN npx playwright install chromium --with-deps +COPY --from=builder /app/node_modules ./node_modules COPY --from=builder /app/dist ./dist CMD ["node", "dist/index.js"]