Skip to content

feat: multichain deploy scripts #1487

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

Open
wants to merge 17 commits into
base: release-dev/multichain
Choose a base branch
from

Conversation

ypatil12
Copy link
Collaborator

@ypatil12 ypatil12 commented Jun 25, 2025

Motivation:

We need deploy scripts for multichain

Modifications:

Adds a crossChainDeployLib from: #1474. This library uses createX for deterministic deployments. In order to keep the same address on all destinationChains, we deploy contracts from the same multisig on each chain.

To distinguish between a source and destination chain we add a SOURCE_CHAIN: bool and DESTINATION_CHAIN: bool to the Zeus Config. We skip parts of the deploy if a chain is not a source or destination.

Deploys the contracts in 4 steps

  1. deploySourceChain.s.sol: Deploys KeyRegistrar, ReleaseManager, CrossChainRegistry.
  2. deployDestinationChainProxies.s.sol: Deploys empty proxy contracts for OperatorTableUpdater, BN254CertificateVerifier, ECDSACertificateVerifier. Note: in order to have deterministic proxies, we need to ensure the initCode is the same. Thus, the implementation is the same emptyContract and the proxyAdmin is initially the multichainDeployerMultisig.
  3. deployDestinationChainImpls: Deploys implementations using EOA
  4. instantiateDestinationChainProxies: Upgrades the proxies to the actual implementations. Transfer proxy admin to the actual proxyAdmin

Result:

Deploy scripts

@ypatil12 ypatil12 force-pushed the feat/deploy-scripts branch from ac34269 to ebd2c17 Compare June 28, 2025 04:33
@ypatil12 ypatil12 requested a review from 0xClandestine June 28, 2025 04:35
@ypatil12 ypatil12 marked this pull request as ready for review June 28, 2025 04:35
@ypatil12 ypatil12 changed the title feat: deploy scripts feat: multichain deploy scripts Jun 28, 2025
@ypatil12 ypatil12 force-pushed the feat/deploy-scripts branch from 0edefd1 to 833d2d0 Compare June 28, 2025 15:13
@ypatil12 ypatil12 force-pushed the release-dev/multichain branch from 8c6266f to 421b314 Compare June 28, 2025 15:14
@ypatil12 ypatil12 force-pushed the feat/deploy-scripts branch from 833d2d0 to 2a52045 Compare June 28, 2025 15:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants