- Deterministic CREATE2 deployments
- Deployment manifest with ABIs and addresses
- Multi-chain support with identical addresses
Building
The build process:
- Recompiles Solidity contracts
- Generates deployment manifests
- Includes ABIs
- Calculates predicted deployment addresses
Configuration
Thecannonfile.toml defines deployment settings:
- Package name and version: Identifies the deployment package
- Dependencies: Pulls from the
cow-settlementpackage (version 2.0.2) - CREATE2 salt: Deterministic salt value for address calculation
- Constructor arguments: Settlement contract address passed automatically from the dependency
Publishing
Publish to Cannon registry
Publishing requires an authorized account with 0.0025 ETH + gas fees on Optimism Mainnet.
Select network and provide credentials
Provide your private key and select the target network when prompted.
CREATE2 Deterministic Deployment
The CREATE2 deployment method ensures the same contract address across all EVM networks. The address is determined by:- Deployer address
- Salt value
- Contract bytecode
- Constructor arguments
Production Deployment
Actual mainnet deployments are handled through the separate cowprotocol/deployments repository, with staging and production phases.Troubleshooting
Build failures
Build failures
Ensure all dependencies are installed with
pnpm install and that you’re using the correct Solidity version (0.8.20).Authorization issues
Authorization issues
Recording commands
Recording commands
Some recording commands may require manual execution. Check the Cannon documentation for the latest commands.
Resources
- cowprotocol/deployments — Production deployment addresses
- Cannon Explorer: cow-omnibus — Package on Cannon registry
- Installation Guide — Local setup and Forge deployment