This repository has been archived on 2024-06-13. You can view files and clone it, but cannot push or open issues or pull requests.
old-shiloh-website/Dockerfile
2023-05-19 12:25:23 -07:00

29 lines
562 B
Docker

# Build stage
FROM node:16-alpine AS build-stage
WORKDIR /app
COPY package.json ./
COPY package-lock.json ./
RUN npm ci --production
COPY next.config.js ./
COPY tailwind.config.js ./
COPY postcss.config.js ./
COPY components ./components
COPY pages ./pages
COPY public ./public
COPY styles ./styles
RUN npm run build
# Production stage
FROM node:16-alpine AS production-stage
WORKDIR /app
COPY --from=build-stage /app/.next ./.next
COPY --from=build-stage /app/public ./public
COPY --from=build-stage /app/node_modules ./node_modules
CMD ["npm", "start"]