feat: add docker ci pack

Signed-off-by: d0zingcat <iamtangli42@gmail.com>
This commit is contained in:
2026-01-13 21:22:45 +08:00
parent c0f383f281
commit 180f3cd825
11 changed files with 60 additions and 56 deletions

26
Dockerfile Normal file
View File

@@ -0,0 +1,26 @@
# Build stage for web
FROM oven/bun:1-alpine AS web-builder
WORKDIR /app
COPY . .
RUN bun install --frozen-lockfile
WORKDIR /app/apps/web
RUN bun run build
# Final stage
FROM oven/bun:1-alpine
WORKDIR /app
# Copy the entire project for monorepo context
COPY . .
# Install dependencies for the server (and shared workspace if any)
RUN bun install --frozen-lockfile
# Copy built web assets to server's public directory
COPY --from=web-builder /app/apps/web/dist /app/apps/server/public
WORKDIR /app/apps/server
EXPOSE 3000
CMD ["bun", "run", "start"]