Repository navigation
fix(docker): upgrade the base image's setuptools in the runtime stage - #870
Merged
Merged
Conversation
python:3.11-slim ships setuptools 79.0.1, below the security extra's floor, and the image installs plain aindy-runtime. Upgrade it in the runtime stage: a builder install copied over /usr/local leaves both dist-infos and pip list still reports 79.0.1. [security] declined, it also installs pip-audit. Verified by a local build: setuptools 84.2.1 is the only dist-info, aindy-runtime 2.29.0, CLI runs, no pip-audit. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Masterplanner25
force-pushed
the
fix/docker-setuptools-floor
branch
from
October 30, 2026 04:15
3b8a8d1 to
d79c801
Compare
Open
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Owner's choice (a) from the #869 discussion: our image should ship the fixed setuptools, and setuptools stays out of the core dependencies.
Problem. The
Dockerfileinstalls plainaindy-runtime==2.29.0, and setuptools's floor lives only in thesecurityextra. The image therefore keepspython:3.11-slim's setuptools 79.0.1, which is below both CVE-2026-59890's floor (83.0.0) and GHSA-xmj3-9gf7-h52w's (84.1.0). There's no runtime exposure, since the runtime never imports setuptools; this is what an image scanner reports.Fix. One step in the runtime stage, after
COPY --from=builder /install /usr/local:Why not the obvious alternatives. Both were checked in throwaway two-stage builds.
aindy-runtime[security]in the builder/usr/localsetuptools-79.0.1.dist-infoand-84.2.1.dist-inforemain;pip liststill says 79.0.1setuptools-84.2.1.dist-info;pip listsays 84.2.1Verified locally on the real Dockerfile (
docker build --no-cache): the image reportsaindy-runtime 2.29.0andsetuptools 84.2.1, with a single setuptools dist-info, no pip-audit, and a workingaindy-runtime --help.Changelog:
changelog.d/870-docker-setuptools-floor.md. It takes effect from the next image build. The floor is duplicated from thesecurityextra; the Dockerfile comment says to keep them equal.The app's Dockerfile is single-stage with a direct
pip install, so its[mcp,security]install already replaces 79.0.1 cleanly. No app change is needed.🤖 Generated with Claude Code