fix: add lightweight migrate Dockerfile target to avoid tsup build failure in CI
Some checks failed
Deploy AgentLens / deploy (push) Failing after 9s
Some checks failed
Deploy AgentLens / deploy (push) Failing after 9s
The migrate service only needs Prisma CLI to run 'prisma db push'. Previously it used the 'builder' target which runs 'npx turbo build' (including sdk-ts needing tsup), causing failures in fresh CI builds over TCP where Docker cache is unavailable. New 'migrate' target copies only node_modules and prisma schema.
This commit is contained in:
@@ -16,6 +16,10 @@ COPY . .
|
||||
RUN npx prisma generate --schema=packages/database/prisma/schema.prisma
|
||||
RUN npx turbo build
|
||||
|
||||
FROM base AS migrate
|
||||
COPY --from=deps /app/node_modules ./node_modules
|
||||
COPY packages/database/prisma ./packages/database/prisma
|
||||
|
||||
FROM base AS web
|
||||
RUN addgroup --system --gid 1001 nodejs && \
|
||||
adduser --system --uid 1001 nextjs
|
||||
|
||||
Reference in New Issue
Block a user