diff --git a/Dockerfile b/Dockerfile index 1718a1f..4226fd8 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,5 +1,8 @@ FROM node:18-alpine +# Install OpenSSL and build tools for native modules +RUN apk add --no-cache openssl openssl-dev python3 make g++ + # Install pnpm RUN npm install -g pnpm @@ -8,18 +11,18 @@ WORKDIR /app # Copy package files COPY package.json pnpm-lock.yaml ./ -# Install dependencies +# Install dependencies (rebuild native modules) RUN pnpm install --force # Copy source COPY . . +# Generate Prisma client +RUN npx prisma generate + # Build RUN pnpm run build -# Run prisma migrations -RUN npx prisma generate - # Create config directory RUN mkdir -p /app/config