opnode
This is the reference implementation of the rollup-node spec.
Compiling
From the repository root:
go build -o op ./opnode/cmd
go test ./opnode/...
Running
Options can be reviewed with:
./op run --help
To start syncing the rollup:
Connect to at least one L1 RPC and L2 execution engine:
Initialize the L2 chain with a genesis.json
chain spec like L1, with the Merge fork activated from genesis.
Specify genesis details:
- L1 number / hash: starting-point of L2 chain inputs
- L2 genesis hash: to confirm we are building on the correct L2 genesis
# websockets or IPC preferred for event notifications to improve sync, http RPC works with adaptive polling.
op node run \
--l1=ws://localhost:8546 --l2=ws//localhost:9001 \
--genesis.l1-num=.... --genesis.l1-hash=..... --genesis.l2-hash=....