Fix Dockerfile: copy prisma schema before npm ci to fix postinstall
This commit is contained in:
@@ -9,8 +9,9 @@ FROM base AS deps
|
||||
RUN apk add --no-cache libc6-compat python3 make g++
|
||||
WORKDIR /app
|
||||
|
||||
# Copy package files
|
||||
# Copy package files AND prisma schema (needed for postinstall: prisma generate)
|
||||
COPY package*.json ./
|
||||
COPY prisma ./prisma/
|
||||
|
||||
# Install dependencies (with legacy peer deps for compatibility)
|
||||
RUN npm ci --legacy-peer-deps
|
||||
@@ -57,6 +58,3 @@ EXPOSE 3000
|
||||
|
||||
ENV PORT=3000
|
||||
ENV HOSTNAME="0.0.0.0"
|
||||
|
||||
# Start the application
|
||||
CMD ["node", "server.js"]
|
||||
|
||||
Reference in New Issue
Block a user