ci(deps): parallelize the image build (per-CPython matrix + assemble) - #276
Merged
Conversation
The single-Dockerfile producer built Boost+eigenpy for all 5 CPythons serially -- ~an hour, and the run we cancelled was still on cp310 after 85 min. Split it: - build-python-deps.sh: builds one CPython's Boost+eigenpy into /opt/deps/<tag> and tars it. - build-ci-image.yml: a `build-deps` MATRIX runs that script per tag in parallel (inside the manylinux container via `docker run`, dodging the node-in-container issue), uploading a deps-<tag>.tar.gz artifact each; `assemble-and-push` downloads them and builds a thin assembly image that just installs the system layer (openmpi/ccache/patchelf/eigen) and unpacks the tarballs -> ~2 min. Dropped the registry buildcache (assembly is cheap). - Dockerfile: reworked from the inline per-Python loop to the COPY-and-unpack assembly. Wall-clock is now one Python's build, not five in series. `deps/` is gitignored. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.
The single-Dockerfile producer built Boost+eigenpy for all 5 CPythons serially — ~an hour, and the run we cancelled was still on cp310 after 85 min. This splits it into a parallel matrix + a thin assembly:
build-python-deps.sh— builds one CPython's Boost+eigenpy into/opt/deps/<tag>and tars it.build-ci-image.yml— abuild-depsmatrix runs that script per tag in parallel (inside the manylinux container viadocker run, which sidesteps the node-in-container problem), each uploading adeps-<tag>.tar.gz.assemble-and-pushdownloads them and builds a thin assembly image (~2 min) that only installs the system layer (openmpi/ccache/patchelf/eigen) and unpacks the tarballs. Dropped the registry buildcache.Dockerfile— reworked from the inline per-Python loop to COPY-and-unpack.Wall-clock ≈ one Python's build, not five in series. Merging (touches
docker/manylinux-deps/**) re-triggers the image build. Still producer-only; nothing consumes the image yet.🤖 Generated with Claude Code