# The System One Arcade Space: game/server.py on one NVIDIA GPU, CUDA graphs on. FROM python:3.12-slim # torch.compile builds its kernels with a C compiler RUN apt-get update && apt-get install -y --no-install-recommends build-essential \ && rm -rf /var/lib/apt/lists/* RUN useradd -m -u 1000 user USER user ENV HOME=/home/user PATH=/home/user/.local/bin:$PATH \ HF_HOME=/home/user/.cache/huggingface PYTHONUNBUFFERED=1 WORKDIR /home/user/app # the same install as a local NVIDIA machine: CUDA 12.6 builds, which older drivers also run COPY --chown=user requirements.txt requirements-nvidia.txt ./ RUN pip install --no-cache-dir --user -r requirements-nvidia.txt COPY --chown=user . . EXPOSE 7860 # HF_TOKEN (a Space secret) reads the model; the server binds once warmed up, about two minutes. CMD ["python", "game/server.py", "--no-token", "--compile", "--host", "0.0.0.0", "--port", "7860"]