Fix Prisma prune: Use --config.ignore-scripts=false to preserve Prisma client
This commit is contained in:
parent
0035b7cceb
commit
cf071cc478
1 changed files with 2 additions and 5 deletions
|
|
@ -25,12 +25,9 @@ RUN pnpm prisma generate
|
||||||
COPY . .
|
COPY . .
|
||||||
RUN pnpm build
|
RUN pnpm build
|
||||||
|
|
||||||
# Remove dev dependencies to reduce image size
|
# Remove dev dependencies to reduce image size (but keep Prisma client)
|
||||||
ENV CI=true
|
ENV CI=true
|
||||||
RUN pnpm prune --prod
|
RUN pnpm prune --prod --config.ignore-scripts=false
|
||||||
|
|
||||||
# Regenerate Prisma client after pruning (since prune removes generated files)
|
|
||||||
RUN npx prisma generate
|
|
||||||
|
|
||||||
# Create uploads directory
|
# Create uploads directory
|
||||||
RUN mkdir -p /app/uploads
|
RUN mkdir -p /app/uploads
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue