feat: initial monorepo scaffold - Next.js 15 + Prisma + Python SDK stubs
- Turborepo monorepo with apps/web and packages/database, sdk-python - Next.js 15 app with professional landing page (dark theme, emerald accent) - Prisma schema: Trace, DecisionPoint, Span, Event models with full indexing - Docker Compose: web (port 4200), postgres:16, redis:7, migrate service - Python SDK package stubs: init, trace decorator, log_decision, integrations - Multi-stage Dockerfile for standalone Next.js production build
This commit is contained in:
26
Dockerfile
Normal file
26
Dockerfile
Normal file
@@ -0,0 +1,26 @@
|
||||
FROM node:20-alpine AS base
|
||||
RUN apk add --no-cache git
|
||||
WORKDIR /app
|
||||
|
||||
FROM base AS deps
|
||||
COPY package.json package-lock.json* ./
|
||||
COPY apps/web/package.json ./apps/web/
|
||||
COPY packages/database/package.json ./packages/database/
|
||||
RUN npm install --production=false
|
||||
|
||||
FROM base AS builder
|
||||
COPY --from=deps /app/node_modules ./node_modules
|
||||
COPY . .
|
||||
RUN npx prisma generate --schema=packages/database/prisma/schema.prisma
|
||||
RUN npx turbo build
|
||||
|
||||
FROM base AS web
|
||||
RUN addgroup --system --gid 1001 nodejs && \
|
||||
adduser --system --uid 1001 nextjs
|
||||
COPY --from=builder --chown=nextjs:nodejs /app/apps/web/.next/standalone ./
|
||||
COPY --from=builder --chown=nextjs:nodejs /app/apps/web/.next/static ./apps/web/.next/static
|
||||
COPY --from=builder --chown=nextjs:nodejs /app/packages/database/prisma ./packages/database/prisma
|
||||
USER nextjs
|
||||
EXPOSE 3000
|
||||
ENV PORT=3000 HOSTNAME="0.0.0.0"
|
||||
CMD ["node", "apps/web/server.js"]
|
||||
Reference in New Issue
Block a user