Download Dockerfile from PRANAV05092003/autonomous-code-refactoring-env: direct link, hf CLI and curl.
- Browser
- Download file 592 Bytes
-
https://huggingface.co/spaces/PRANAV05092003/autonomous-code-refactoring-env/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/PRANAV05092003/autonomous-code-refactoring-env/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/PRANAV05092003/autonomous-code-refactoring-env/resolve/main/Dockerfile
592 Bytes
| FROM python:3.11-slim | |
| WORKDIR /app | |
| RUN apt-get update && apt-get install -y --no-install-recommends \ | |
| build-essential \ | |
| && rm -rf /var/lib/apt/lists/* | |
| COPY requirements.txt . | |
| RUN pip install --no-cache-dir -r requirements.txt | |
| COPY . . | |
| ENV API_BASE_URL=https://api.openai.com/v1 | |
| ENV MODEL_NAME=gpt-4o-mini | |
| ENV PORT=7860 | |
| EXPOSE 7860 | |
| HEALTHCHECK --interval=30s --timeout=10s --start-period=5s --retries=3 \ | |
| CMD python -c "import requests; requests.get('http://localhost:7860/health').raise_for_status()" | |
| CMD ["uvicorn", "server.app:app", "--host", "0.0.0.0", "--port", "7860"] | |