# frontend/Dockerfile FROM node:20-alpine AS builder WORKDIR /app COPY package*.json ./ RUN npm ci # clean install, respects lockfile COPY . . RUN npm run build # produces ./dist # ---- Runtime image (optional) ---- FROM nginx:stable-alpine COPY --from=builder /app/dist /usr/share/nginx/html EXPOSE 80 CMD ["nginx", "-g", "daemon off;"]