Skip to content

ci(deps): parallelize the image build (per-CPython matrix + assemble) - #276

Merged
ofloveandhate merged 1 commit into
developfrom
ci-image-parallel
Jul 7, 2026
Merged

ci(deps): parallelize the image build (per-CPython matrix + assemble)#276
ofloveandhate merged 1 commit into
developfrom
ci-image-parallel

Conversation

@ofloveandhate

Copy link
Copy Markdown
Contributor

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 — a build-deps matrix runs that script per tag in parallel (inside the manylinux container via docker run, which sidesteps the node-in-container problem), each uploading a deps-<tag>.tar.gz. assemble-and-push downloads 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

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>
@ofloveandhate
ofloveandhate merged commit fc28855 into develop Jul 7, 2026
5 of 16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant