Compare commits

..

1 Commits

Author SHA1 Message Date
06e135a941 fix(orchestrator): use symlink path in prisma:generate script
All checks were successful
ci/woodpecker/push/ci Pipeline was successful
PR #707 added the symlink apps/orchestrator/prisma/schema.prisma but
accidentally reverted the script back to ../api/prisma/schema.prisma.

Docker does not have apps/api/prisma/ — the symlink IS the schema.
Change script to ./prisma/schema.prisma so both CI (symlink resolved)
and Docker (symlink followed by kaniko COPY) work correctly.
2026-03-07 10:31:41 -06:00

View File

@@ -47,14 +47,11 @@ 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/apps/orchestrator/node_modules ./apps/orchestrator/node_modules
# The repo has apps/orchestrator/prisma/schema.prisma as a symlink for CI use.
# Kaniko resolves destination symlinks on COPY, which fails because the symlink
# target (../../api/prisma/schema.prisma) doesn't exist in the container.
# Fix: remove the dangling symlink first, then copy the real schema file there.
RUN rm -f apps/orchestrator/prisma/schema.prisma
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.
# apps/orchestrator/prisma/schema.prisma is a symlink → ../../api/prisma/schema.prisma
# Docker COPY follows symlinks, so the schema file is already present after
# "COPY apps/orchestrator ./apps/orchestrator" above.
# pnpm turbo build runs prisma:generate first (which uses --schema=./prisma/schema.prisma)
# from within the orchestrator package — no cross-package project-root issues.
# Build the orchestrator app using TurboRepo
RUN pnpm turbo build --filter=@mosaic/orchestrator