minesweeper-frontend/Dockerfile
Jose134 815f9048d6
All checks were successful
gitea/minesweeper-frontend/pipeline/head This commit looks good
Fix deployment
2025-01-22 12:22:12 +01:00

13 lines
328 B
Docker

FROM node:20-alpine as builder
WORKDIR /app
COPY . .
ARG VITE_SOCKET_URL
ENV VITE_SOCKET_URL $VITE_SOCKET_URL
RUN npm install
RUN npm run build
FROM nginx:1.25.4-alpine-slim as prod
COPY --from=builder /app/dist /usr/share/nginx/html
COPY nginx.conf /etc/nginx/conf.d
EXPOSE 5173
CMD ["nginx", "-g", "daemon off;"]