# Stage 1: Build Angular application FROM node:18-alpine AS builder WORKDIR /app # Copy package files COPY package*.json ./ # Install dependencies with legacy peer deps flag RUN npm ci --legacy-peer-deps # Copy source code COPY . . # Build for production RUN npm run build -- --configuration production --progress=true # Stage 2: Serve with Nginx FROM nginx:alpine AS production # Copy built artifacts from builder COPY --from=builder /app/dist/fuse-angular /usr/share/nginx/html # Expose port 80 EXPOSE 80 # Run nginx CMD ["nginx", "-g", "daemon off;"]