cdk-opgeth-sovereign) devnet.
Prerequisites
Before starting, ensure you have:- A valid L1 RPC URL
- A wallet address with Sepolia testnet funds (deployer)
- Docker (or any other container orchestrator of your choice)
- Cast
- Polycli
- Reference Repo (configuration files used in the guide)
The values shown are specific to this example. Replace them with values relevant to your own setup.
Rollup Network Creation
Step 1: Submit a Request
To initiate the rollup creation:- The Implementation Provider (IP) must submit a request to Polygon Labs.
- Use the Polygon Support Portal to raise a support ticket.
Required Parameters
Step 2: Setup by Polygon Labs
Once approved:- Polygon Labs provisions your Rollup.
- A transaction is recorded (e.g., example).
combined.json: Core deployment detailsgenesis-base.json: Needed for genesis generation
Genesis File Generation
Option Selection
Choose one:- Option 1 (Recommended): Merge OP + Polygon Genesis with pre-deployed contracts.
- Option 2: Manual L2 contract deployment.
Step-by-Step Instructions
- Environment Setup
v10.0.0-rc.7 in this example
- Parameter File Creation
combined.json and your wallet addresses.
- Base Genesis Template
genesis-base.json into this file.
- Generate Genesis Files
- Rename the Output Files for Clarity
Network Deployment
Environment Variables
The values shown are specific to this example. Replace them with values relevant to your own setup.
L2 Deployment (Using op-deployer)
To set up your Layer 2 (L2) network using the OP Stack, we recommend starting with the official Optimism L2 Rollup tutorial. This guide provides a practical reference based on that tutorial and uses the op-deployer tool to streamline the deployment process.All commands in this section are executed from the root directory of your project.
- Initialize deployer Folder
-
Edit
intent.tomlwith your parameters. - Deploy L1 Contracts
- Merge Genesis Files
polygon-genesis.json file with the OP Stack’s genesis.json. The recommended approach is to embed the contents of polygon-genesis.json directly into the op-deployer state.
- Generate Files
Component Setup
OP Stack
- Create
.envvalues
The values shown are specific to this example. Replace them with values relevant to your own setup.
- Generate secret
- Fund the batcher wallet on L1
- Initialize Data Directory
- Start Services
Aggkit
- Config
config/aggkit.toml and config/bridge.toml config files with the relevant information from your combined.json, polygon-genesis-info.json and your wallet addresses.
- Create keystore files
- Fund ClaimTX & Aggoracle
- Start PostgreSQL DB
- Run Services
Bridge
Environment Variables
The values shown are specific to this example. Replace them with values relevant to your own setup.
L1 to L2
- Initiate the Deposit from L1
- Verify the Deposit on L2
L2 to L1
- Initiate a Deposit
- Wait for the Pessimistic Proof
- Verify the Deposit Status
"ready_for_claim": true, the deposit is ready to be claimed.
- Claim the Deposit on L1
- Confirm the Claim
Your PP network is now live.