FROM python:3.9-slim # System dependencies RUN apt-get update && apt-get install -y \ libopenblas-dev \ # For numpy && rm -rf /var/lib/apt/lists/* # Cache directory RUN mkdir -p /tmp/huggingface && chmod 777 /tmp/huggingface WORKDIR /app COPY . . # Install Python deps RUN pip install --no-cache-dir -r requirements.txt CMD ["python", "-c", "import os; os.system('ulimit -v 2000000'); python app.py"] HEALTHCHECK --interval=30s --timeout=3s \ CMD curl -f http://localhost:8000/ready || exit 1