Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 9 additions & 8 deletions frontend/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,21 +1,22 @@
# Development stage
FROM node:22-alpine AS development
RUN apk upgrade --no-cache \
&& npm install -g npm@latest
RUN apk upgrade --no-cache
WORKDIR /app
COPY package*.json ./
RUN npm i
RUN npm ci
COPY . .
EXPOSE 3000
CMD ["npm", "run", "dev"]

# Build stage
FROM node:22-alpine AS build
RUN apk upgrade --no-cache \
&& npm install -g npm@latest
# Build stage — always on the native builder arch.
# Cross-compiling Node/npm under QEMU for linux/arm64 crashes with
# "qemu: uncaught target signal 4 (Illegal instruction)". Vite output is
# architecture-independent static files, so building on $BUILDPLATFORM is safe.
FROM --platform=$BUILDPLATFORM node:22-alpine AS build
RUN apk upgrade --no-cache
WORKDIR /app
COPY package*.json ./
RUN npm i --include=dev
RUN npm ci --include=dev
COPY . .
RUN npm run build

Expand Down
Loading