# syntax=docker/dockerfile:1 # BUILD STAGE FROM node:22-alpine AS builder WORKDIR /app COPY package*.json ./ RUN npm ci # Copy .env.docker as .env for Vite COPY .env.docker .env COPY . . # Compile TypeScript & create optimized production build RUN npm run build # PRODUCTION STAGE FROM nginx:alpine AS production # Copy production build files to nginx COPY --from=builder /app/dist /usr/share/nginx/html COPY nginx.conf /etc/nginx/conf.d/default.conf EXPOSE 80