# Ore Compute worker container runtime. Built locally by install.sh from the
# verified package. Requires the NVIDIA Container Toolkit on the host.
FROM nvidia/cuda:12.8.1-runtime-ubuntu24.04
RUN apt-get update && apt-get install -y --no-install-recommends python3 python3-venv ca-certificates \
 && rm -rf /var/lib/apt/lists/*
COPY wheels /opt/ore/wheels
RUN python3 -m venv /opt/ore/venv \
 && /opt/ore/venv/bin/pip install --no-cache-dir /opt/ore/wheels/*.whl numpy==2.5.3 blake3==1.0.11
COPY ore_worker /opt/ore/ore_worker
COPY LICENSE NOTICE.md THIRD_PARTY_NOTICES.txt /opt/ore/
ENV PYTHONPATH=/opt/ore PYTHONDONTWRITEBYTECODE=1 PYTHONUNBUFFERED=1
USER 65534:65534
ENTRYPOINT ["/opt/ore/venv/bin/python", "-I", "-c", "import sys; sys.path.insert(0, sys.argv.pop(1)); from ore_worker.cli import main; raise SystemExit(main())", "/opt/ore"]
