| FROM node:18-alpine | |
| WORKDIR /app | |
| # Install build tools for native modules | |
| RUN apk add --no-cache python3 make g++ | |
| # Install dependencies | |
| COPY package*.json ./ | |
| RUN npm ci | |
| # Copy source | |
| COPY . . | |
| # Build TypeScript | |
| RUN npm run build | |
| # Hugging Face uses this port | |
| EXPOSE 7860 | |
| # Start server | |
| CMD ["node", "dist/index.js"] |