Files
bjoernpoettker 23a889f3a5
Build and Push Multi-Platform Images / build-and-push (push) Successful in 33s
fix: install git in backend Docker build stage
Required for npm packages that reference git dependencies.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-21 21:41:10 +02:00

20 lines
435 B
Docker

# Backend
FROM node:20-alpine AS builder
RUN apk add --no-cache git
WORKDIR /app
COPY package*.json ./
RUN npm ci
COPY . .
RUN npm run build
# Production
FROM node:20-alpine
RUN apk add --no-cache ghostscript imagemagick font-liberation fontconfig
WORKDIR /app
COPY --from=builder /app/dist ./dist
COPY --from=builder /app/node_modules ./node_modules
COPY --from=builder /app/package.json ./
EXPOSE 3100
CMD ["node", "dist/main.js"]