This commit is contained in:
2026-05-14 19:24:50 +00:00
parent af0628867f
commit a7f218e182
63 changed files with 10539 additions and 0 deletions

32
Dockerfile Normal file
View File

@@ -0,0 +1,32 @@
# syntax=docker/dockerfile:1.7
FROM node:20-alpine AS builder
RUN corepack enable
WORKDIR /build
COPY package.json pnpm-workspace.yaml pnpm-lock.yaml tsconfig.base.json ./
COPY apps/server/package.json ./apps/server/
COPY apps/web/package.json ./apps/web/
RUN pnpm install --frozen-lockfile
COPY apps/server ./apps/server
COPY apps/web ./apps/web
RUN pnpm build
RUN pnpm deploy --filter=@boocode/server --prod --legacy /out/server
FROM node:20-alpine AS runtime
RUN apk add --no-cache ripgrep
WORKDIR /app
COPY --from=builder /out/server ./
COPY --from=builder /build/apps/web/dist ./web
ENV NODE_ENV=production
ENV WEB_DIST_PATH=/app/web
EXPOSE 3000
CMD ["node", "dist/index.js"]