Dockerfile 383 B

12345678910111213141516171819202122232425
  1. FROM node:current-alpine
  2. WORKDIR /app
  3. RUN corepack enable
  4. COPY . .
  5. RUN pnpm i --frozen-lockfile
  6. RUN pnpm --filter server build
  7. RUN pnpm --filter server deploy pruned --prod
  8. FROM node:current-alpine
  9. WORKDIR /app
  10. RUN corepack enable
  11. ENV NODE_ENV=production
  12. COPY --from=0 /app/pruned/dist .
  13. COPY --from=0 /app/pruned/node_modules node_modules
  14. EXPOSE 80
  15. CMD [ "node", "index" ]