FROM python:3.14.3-alpine@sha256:faee120f7885a06fcc9677922331391fa690d911c020abb9e8025ff3d908e510

RUN pip3 install --upgrade --quiet pip

# the specific versions of python protobuf tools are in hack/dev-requirements.txt so that Dependabot can bump them for updates
ADD hack/dev-requirements.txt .

RUN pip3 install -r dev-requirements.txt

COPY --from=protoc-base:python /protobuf/bin/protoc /usr/local/bin/
COPY --from=protoc-base:python /protobuf/include/google /opt/include/google
COPY --from=protoc-base:python /googleapis /googleapis

ENTRYPOINT ["/usr/local/bin/protoc" ]
