Fix Docker build: disable Turbopack for file: linked SDK compatibility
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
9d3c8ee5dc
commit
0e05f3a5ab
10
Dockerfile
10
Dockerfile
|
|
@ -12,14 +12,18 @@ COPY encryptid-sdk /encryptid-sdk/
|
|||
# Install dependencies
|
||||
RUN npm ci || npm install
|
||||
|
||||
# Copy source files
|
||||
# Copy source files, then restore node_modules
|
||||
COPY rvote-online/ .
|
||||
RUN rm -rf node_modules .next
|
||||
|
||||
# Re-install to get clean node_modules with SDK resolved
|
||||
RUN npm ci || npm install
|
||||
|
||||
# Generate Prisma client
|
||||
RUN npx prisma generate
|
||||
|
||||
# Build the application
|
||||
RUN npm run build
|
||||
# Build the application (use webpack - Turbopack has issues with file: linked subpath exports)
|
||||
RUN npx next build --no-turbopack
|
||||
|
||||
# Production stage
|
||||
FROM node:20-alpine AS runner
|
||||
|
|
|
|||
Loading…
Reference in New Issue