#35722 ci: cache BSD sdk sources separately
https://github.com/bitcoin/bitcoin/pull/35722 · · +120/-69 in 6 files, 3 commits · labels: Tests, Needs rebase
Goal
- Avoid re-downloading BSD SDK archives from external mirrors when the container cache misses
- Reduces wasted CI run time and avoids potential failures from unresponsive upstream mirrors
Extracts the BSD SDK archive downloads from the base container image build into a standalone script run inside the container, and caches the SDK downloads using GitHub Actions caching. It also unifies cache source and destination mount definitions in `ci/test/02_run_container.py`.
Problem: When the BSD CI container base image cache misses, CI jobs re-download SDK archives directly from external upstream BSD mirrors, wasting time and risking job failure if those mirrors are unresponsive.
Category: Build and CI (#41 of 55)
P3 · speedup
- P3 because addresses an inefficiency rather than an active CI failure
- Slightly speeds up CI and reduces external mirror bandwidth usage on container cache misses
Reduces external bandwidth usage and CI build times on container cache misses by caching BSD SDK archives separately. As author willcl-ark admitted ('I do not [recall CI logs failing], it was just the re-downloading them needlessly which prompted this change'), this addresses an inefficiency rather than an active CI outage, making it a worthwhile but deferrable optimization.
Membership: Modifies GitHub Actions cache actions and container setup scripts under ci/test/.
Factors: security/stability 1, bug 0, performance 1, user value 0, leverage 0
Reviewability: Stale: Needs rebase
- Needs rebase due to merge conflicts with master
The PR has merge conflicts with master (conflicts with #35754) and was pinged for rebase on 2026-09-16.
Author status: silent since 2026-08-04; pinged for rebase on 2026-09-16
Open concerns:
- maflcko asked whether any CI failures had actually been observed from these downloads, to which the author clarified that the change was prompted only by needless re-downloading rather than observed failures.
- maflcko suggested adding fallback mirrors like depends as a potential alternative, though noted caching may also be fine.
Agreement: Neutral
- No reviews or approvals yet
- Questioned whether download failures have actually occurred in CI (maflcko)
- Suggested fallback mirrors as an alternative approach to caching (maflcko)
Neutral; maflcko suggested fallback mirrors as an alternative and questioned if failures occur, no ACKs yet.
No reviewer has reviewed or ACKed the PR yet. maflcko floated fallback mirrors as an alternative approach and questioned if downloads had actually failed; author acknowledged both options are viable.
- maflcko: 'An alternative would be to add fallback mirrors (like in depends), but this may be fine as well (haven't looked closely)'
- maflcko: 'Do you recall any CI logs where the download failed?'
- willcl-ark: 'I do not, it was just the re-downloading them needlessly which prompted this change.'
- sedited: 'Ping for rebase.'
Review verdicts (DrahtBot): 0
Files
160 lines under test/bench/ci.
- ci/test/02_run_container.py +35/-29
- ci/test/01_setup_bsd.sh +56/-0
- ci/test/01_base_install.sh +0/-40
- .github/actions/cache/restore/action.yml +10/-0
- .github/actions/configure-environment/action.yml +10/-0
- .github/actions/cache/save/action.yml +9/-0
Card
This PR moves BSD SDK downloads out of the base container image build into a dedicated setup script and caches them via GitHub Actions cache actions, mounting them at container runtime. It avoids redundant downloads from BSD mirrors when the CI container base image cache expires. While useful for CI efficiency, the author confirmed no CI failures have actually been observed from the existing downloads, and maflcko suggested fallback mirrors as an alternate approach. The branch has merge conflicts and is waiting on an author rebase.