|
|
|
@@ -21,8 +21,7 @@ FROM base AS deps
|
|
|
|
COPY packages/shared/package.json ./packages/shared/
|
|
|
|
COPY packages/shared/package.json ./packages/shared/
|
|
|
|
COPY packages/config/package.json ./packages/config/
|
|
|
|
COPY packages/config/package.json ./packages/config/
|
|
|
|
COPY apps/orchestrator/package.json ./apps/orchestrator/
|
|
|
|
COPY apps/orchestrator/package.json ./apps/orchestrator/
|
|
|
|
# Copy API prisma schema so prisma generate can run in the orchestrator build
|
|
|
|
# API schema is available via apps/orchestrator/prisma/schema.prisma symlink
|
|
|
|
COPY apps/api/prisma ./apps/api/prisma
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Copy npm configuration for native binary architecture hints
|
|
|
|
# Copy npm configuration for native binary architecture hints
|
|
|
|
COPY .npmrc ./
|
|
|
|
COPY .npmrc ./
|
|
|
|
@@ -48,9 +47,13 @@ COPY --from=deps /app/packages/shared/node_modules ./packages/shared/node_module
|
|
|
|
COPY --from=deps /app/packages/config/node_modules ./packages/config/node_modules
|
|
|
|
COPY --from=deps /app/packages/config/node_modules ./packages/config/node_modules
|
|
|
|
COPY --from=deps /app/apps/orchestrator/node_modules ./apps/orchestrator/node_modules
|
|
|
|
COPY --from=deps /app/apps/orchestrator/node_modules ./apps/orchestrator/node_modules
|
|
|
|
|
|
|
|
|
|
|
|
# Copy API prisma schema and generate the Prisma client for the orchestrator
|
|
|
|
# Overwrite the symlink (apps/orchestrator/prisma/schema.prisma → ../../api/prisma/schema.prisma)
|
|
|
|
COPY apps/api/prisma ./apps/api/prisma
|
|
|
|
# with the real file content. Kaniko copies symlinks AS symlinks (does not follow them),
|
|
|
|
RUN pnpm --filter=@mosaic/orchestrator prisma:generate
|
|
|
|
# so the symlink target would be dangling inside the container. Copying the actual file
|
|
|
|
|
|
|
|
# after the orchestrator COPY overwrites the symlink with the resolved content.
|
|
|
|
|
|
|
|
COPY apps/api/prisma/schema.prisma ./apps/orchestrator/prisma/schema.prisma
|
|
|
|
|
|
|
|
# pnpm turbo build runs prisma:generate (--schema=./prisma/schema.prisma) from the
|
|
|
|
|
|
|
|
# orchestrator package context — no cross-package project-root issues.
|
|
|
|
|
|
|
|
|
|
|
|
# Build the orchestrator app using TurboRepo
|
|
|
|
# Build the orchestrator app using TurboRepo
|
|
|
|
RUN pnpm turbo build --filter=@mosaic/orchestrator
|
|
|
|
RUN pnpm turbo build --filter=@mosaic/orchestrator
|
|
|
|
|