-
Notifications
You must be signed in to change notification settings - Fork 133
chore(l2): do not use docker to compile prover except on releases #5315
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR optimizes the prover compilation process by making Docker usage optional, controlled by the PROVER_REPRODUCIBLE_BUILD environment variable. This significantly reduces compilation time (from ~15 minutes on Mac) during development while maintaining reproducible builds for releases.
Key Changes:
- Docker-based compilation is now opt-in via
PROVER_REPRODUCIBLE_BUILDenvironment variable - Both RISC0 and SP1 guest program builds conditionally use Docker when the variable is set
- GitHub release workflow automatically sets
PROVER_REPRODUCIBLE_BUILD=trueto ensure reproducible builds
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| crates/l2/prover/src/guest_program/build.rs | Adds conditional logic to use Docker for guest program builds only when PROVER_REPRODUCIBLE_BUILD is set |
| .github/workflows/tag_release.yaml | Sets PROVER_REPRODUCIBLE_BUILD=true environment variable to enable reproducible builds for releases |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Lines of code reportTotal lines added: Detailed view |
Co-authored-by: Copilot <[email protected]>
Motivation
We use docker to generate reproducible guest program elfs. This slows down a lot the compilation time (about 15 minutes in a Mac).
Description
Don't use docker by default but only when releasing binaries. The docker build is triggered by setting the
PROVER_REPRODUCIBLE_BUILDenv var.