Spaces:
Running
Running
Download Dockerfile from FineEnvs/PortSimEnv-Eval: direct link, hf CLI and curl.
- Browser
- Download file 1.21 kB
-
https://huggingface.co/spaces/FineEnvs/PortSimEnv-Eval/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/FineEnvs/PortSimEnv-Eval/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/FineEnvs/PortSimEnv-Eval/resolve/main/Dockerfile
1.21 kB
| # PortSimEnv v1 eval explorer: the viewer and its read-only JSON, no environment sessions. | |
| # Build context: this folder (core/, openenv/, tasks/ side by side). Rollouts: the bucket, mounted at /data. | |
| FROM python:3.12-slim | |
| ENV PYTHONUNBUFFERED=1 PIP_NO_CACHE_DIR=1 HOME=/home/user PORT=8000 \ | |
| BERTH_TASKS_DIR=/app/tasks/dock-v1-eval:/app/tasks/dock-v1-train BERTH_RUNS_DIR=/data/rollouts \ | |
| BERTH_VIEWER_MODE=explorer BERTH_PLAY_URL=https://huggingface.co/spaces/FineEnvs/PortSimEnv | |
| WORKDIR /app | |
| COPY core /app/core | |
| COPY openenv /app/openenv | |
| COPY tasks /app/tasks | |
| COPY fetch_assets.py /app/fetch_assets.py | |
| # berth_openenv without the environment's dependencies: the explorer imports only api.py (FastAPI + berth_core) | |
| RUN pip install /app/core "fastapi>=0.110" "uvicorn[standard]>=0.30" && pip install --no-deps /app/openenv \ | |
| && python /app/fetch_assets.py && useradd --create-home --uid 1000 user && chown -R user:user /app | |
| USER user | |
| EXPOSE 8000 | |
| HEALTHCHECK --interval=30s --timeout=5s --start-period=30s \ | |
| CMD python -c "import urllib.request; urllib.request.urlopen('http://127.0.0.1:8000/healthz')" | |
| CMD ["sh", "-c", "uvicorn berth_openenv.explorer:app --host 0.0.0.0 --port ${PORT:-8000}"] | |