| FROM node:18-slim | |
| WORKDIR /app | |
| # Install required dependencies including curl | |
| RUN apt-get update && apt-get install -y \ | |
| curl \ | |
| ca-certificates \ | |
| zstd \ | |
| xz-utils \ | |
| procps \ | |
| && rm -rf /var/lib/apt/lists/* | |
| # Install Ollama | |
| RUN curl -fsSL https://ollama.com/install.sh | sh | |
| # Copy application files | |
| COPY package*.json ./ | |
| RUN npm install | |
| COPY . . | |
| # Make start script executable | |
| RUN chmod +x /app/start.sh | |
| # Expose port | |
| EXPOSE 7860 | |
| # Start the application | |
| CMD ["/app/start.sh"] |