# Build stage FROM node:18-alpine AS build WORKDIR /app COPY frontend/package.json . RUN npm install COPY frontend/ . ARG REACT_APP_API_URL=http://localhost:8000 ENV REACT_APP_API_URL=$REACT_APP_API_URL RUN npm run build # Serve with nginx FROM nginx:alpine COPY --from=build /app/build /usr/share/nginx/html EXPOSE 3000 CMD ["nginx", "-g", "daemon off;"]