chore: dockerize monorepo with multi-stage builds and update frontend

This commit is contained in:
s.esmaeili
2026-09-10 20:11:27 +03:30
parent d6f9d63e14
commit efb0051ab9
28 changed files with 4179 additions and 1069 deletions
+22
View File
@@ -0,0 +1,22 @@
FROM node:20-alpine AS builder
ENV PNPM_HOME="/pnpm"
ENV PATH="$PNPM_HOME:$PATH"
RUN corepack enable pnpm
WORKDIR /app
COPY . .
RUN pnpm install --frozen-lockfile
RUN pnpm --filter @lucky-wheel/api build
RUN pnpm deploy --filter @lucky-wheel/api --prod /prod/api
FROM node:20-alpine AS runner
WORKDIR /app
COPY --from=builder /prod/api .
EXPOSE 3000
CMD ["node", "dist/src/main"]