wagerkit / frontend /Dockerfile
saadrizvi09
init
b2806e8
raw
history blame contribute delete
503 Bytes
# Frontend Dockerfile
FROM node:20-alpine AS builder
WORKDIR /app
# Copy package files
COPY package*.json ./
# Install dependencies
RUN npm ci
# Copy source
COPY . .
# Build Next.js app
RUN npm run build
# Production runtime
FROM node:20-alpine
WORKDIR /app
# Copy standalone build
COPY --from=builder /app/.next/standalone ./
COPY --from=builder /app/.next/static ./.next/static
COPY --from=builder /app/public ./public
# Expose port
EXPOSE 3000
# Start application
CMD ["node", "server.js"]