Skip to content

refactor dockerfile & docker build process - #3474

Merged
syphar merged 1 commit into
rust-lang:mainfrom
syphar:new-docker
Aug 26, 2026
Merged

refactor dockerfile & docker build process#3474
syphar merged 1 commit into
rust-lang:mainfrom
syphar:new-docker

Conversation

@syphar

@syphar syphar commented Aug 26, 2026

Copy link
Copy Markdown
Member
  • Build all Docker images together using Buildx Bake.
  • Improve dependency and incremental build caching across CI runs and for local development
  • Share common Dockerfile stages between image targets.
  • only apt install what is actually needed by each stage.
  • Build only the binary required by each image.
  • Smoke-test every packaged binary in CI.
  • don't build/copy the legacy cratesfyi binary any more, we'll definitely not use it in the new infra.
  • move GIT_SHA docker arg into the binary build stages, so the chef dependency layer isn't invalidated for each new commit.

I think this is now a good balance between CI docker build time, and local incremental docker build time. I imagine having had this on my old mac would have made my life much easier.

@syphar syphar self-assigned this Aug 26, 2026
@github-actions github-actions Bot added the S-waiting-on-review Status: This pull request has been implemented and needs to be reviewed label Aug 26, 2026
@syphar
syphar force-pushed the new-docker branch 4 times, most recently from 4b0aa4b to e59c205 Compare August 26, 2026 12:43
@syphar
syphar marked this pull request as ready for review August 26, 2026 13:10
@syphar
syphar requested a review from a team as a code owner August 26, 2026 13:10
@syphar

syphar commented Aug 26, 2026

Copy link
Copy Markdown
Member Author

r? @GuillaumeGomez

@rustbot rustbot assigned GuillaumeGomez and unassigned syphar Aug 26, 2026
@rustbot

rustbot commented Aug 26, 2026

Copy link
Copy Markdown
Collaborator

This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed.

Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers.

@syphar
syphar merged commit 79f294f into rust-lang:main Aug 26, 2026
9 checks passed
@syphar
syphar deleted the new-docker branch August 26, 2026 13:53
@github-actions github-actions Bot added S-waiting-on-deploy This PR is ready to be merged, but is waiting for an admin to have time to deploy it and removed S-waiting-on-review Status: This pull request has been implemented and needs to be reviewed labels Aug 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-deploy This PR is ready to be merged, but is waiting for an admin to have time to deploy it

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants