Spaces:
Build error
Build error
File size: 617 Bytes
1eae852 4b63f89 333c51a 4b63f89 3eebcd0 1eae852 31af3f9 1eae852 4b63f89 1eae852 4b63f89 1eae852 333c51a 4b63f89 1eae852 4b63f89 1eae852 4b63f89 1eae852 b5b5794 1eae852 31af3f9 b5b5794 4b63f89 3eebcd0 31de075 3eebcd0 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 | FROM node:20-slim
WORKDIR /app
# Install dependencies for Prisma and native modules
RUN apt-get update && apt-get install -y openssl python3 make g++ && rm -rf /var/lib/apt/lists/*
# Copy package files
COPY package.json package-lock.json ./
# Install dependencies
RUN npm ci
# Copy source files
COPY . .
# Generate Prisma client
RUN npx prisma generate
# Build the application
RUN npm run build
# Environment variables
ENV NODE_ENV=production
ENV PORT=7860
ENV HOST=0.0.0.0
EXPOSE 7860
# Use entrypoint to handle migrations
ENTRYPOINT ["sh", "/app/entrypoint.sh"]
CMD ["node", ".next/standalone/server.js"]
|