FROM docker.io/library/python:3.12-slim

# Excluded from aggressive image prunes alongside the sandbox image - see the
# Dockerfile at the tree root for the filter.
LABEL io.umwelt.managed="true"

# Pre-create the mount point: the sandbox is launched --read-only, so the
# ro-bound config must land on a path that already exists in the image.
RUN mkdir -p /etc/umwelt
COPY entrypoint.py /opt/umwelt/entrypoint.py

ENV PYTHONUNBUFFERED=1 \
    PYTHONDONTWRITEBYTECODE=1 \
    INGRESS_CONFIG_FILE=/etc/umwelt/ingress.json

ENTRYPOINT ["python3", "/opt/umwelt/entrypoint.py"]
