Files
idea.llm.gitea.repo.docker.…/templates/nodejs/vite-react/Dockerfile.template
2026-01-26 22:33:55 -06:00

24 lines
399 B
Docker

# Stage 1: Build
FROM node:{{NODE_VERSION}}-alpine AS builder
WORKDIR /app
COPY package.json package-lock.json* ./
RUN npm ci
COPY . .
RUN npm run build
# Stage 2: Production (Nginx)
FROM nginx:alpine
# Copy built files
COPY --from=builder /app/dist /usr/share/nginx/html
# Copy nginx configuration
COPY nginx.conf /etc/nginx/conf.d/default.conf
EXPOSE 80
CMD ["nginx", "-g", "daemon off;"]