Spaces:
Sleeping
Sleeping
Download Dockerfile from dpv007/HydroSense: direct link, hf CLI and curl.
- Browser
- Download file 561 Bytes
-
https://huggingface.co/spaces/dpv007/HydroSense/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/dpv007/HydroSense/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/dpv007/HydroSense/resolve/main/Dockerfile
561 Bytes
| FROM node:20-alpine | |
| # Set environment variables for Hugging Face Spaces | |
| ENV PORT=3000 | |
| ENV HOST=0.0.0.0 | |
| # Set working directory | |
| WORKDIR /app | |
| # Install dependencies | |
| COPY package*.json ./ | |
| RUN npm install | |
| # Copy application files | |
| COPY . . | |
| # Generate Prisma Client | |
| RUN npx prisma generate | |
| # Build Next.js app | |
| RUN npm run build | |
| # Set production environment ONLY AFTER building | |
| ENV NODE_ENV=production | |
| # Make the start script executable | |
| RUN chmod +x start.sh | |
| # Expose the port matching README.md | |
| EXPOSE 3000 | |
| # Run the unified start script | |
| CMD ["./start.sh"] | |