Setup
Make sure to first install the prerequisites from the quickstart section before proceeding.
Installation
Before you can start migrating your rollup, you'll need to build and install Kailua's binaries by calling the following commands from the root project directory:
At the cost of longer compilation time, you can embed the RISC Zero zkvm prover logic into kailua-cli
instead of
having it utilize your locally installed RISC Zero r0vm
for proving.
To do this, add -F prove
to the install command below.
For GPU-accelerated local proving, use one of the following feature flags:
- Apple:
-F metal
- Nvidia:
-F cuda
CLI Binary
cargo install kailua-cli --path bin/cli --locked
Configuration
Once your installation is successful, you should be able to run the following command to fetch the Kailua configuration parameters for your rollup instance:
kailua-cli config --op-node-url [YOUR_OP_NODE_URL] --op-geth-url [YOUR_OP_GETH_URL] --eth-rpc-url [YOUR_ETH_RPC_URL]
Running the above command against the respective Base mainnet endpoints should produce the following output:
RISC0_VERSION: 2.2.0
KAILUA_FPVM_KONA_ID: 0xB89DC26172C4CB2DD4F4B6C8DE5119AC69C79036F6448813303C6B4617A147A6
KAILUA_FPVM_HOKULEA_ID: 0xE2556797EF758B82B6DA26555103CAAD7C2074A795F3D619ABC8C052042F6D76
KAILUA_DA_HOKULEA_ID: 0xE6AE1F0EE0FEE9E253DB02250FAD8C0C8DC65141A0042A879FBACBDAE50EA2CB
KAILUA_FPVM_KONA_ELF_SIZE: 35.3 MiB
KAILUA_FPVM_HOKULEA_ELF_SIZE: 38.5 MiB
KAILUA_DA_HOKULEA_ELF_SIZE: 2.9 MiB
CONTROL_ROOT: 0xCE52BF56033842021AF3CF6DB8A50D1B7535C125A34F1A22C6FDCF002C5A1529
CONTROL_ID: 0x04446E66D300EB7FB45C9726BB53C793DDA407A62E9601618BB43C5C14657AC0
RISC_ZERO_VERIFIER: 0x8EAB2D97DFCE405A1692A21B3FF3A172D593D319
GENESIS_TIMESTAMP: 1686789347
BLOCK_TIME: 2
ROLLUP_CONFIG_HASH: 0x0D2CFA12746085B0CBFCB344D7100F873BA380535218A0795F9F4DE43EA92AE7
DISPUTE_GAME_FACTORY: 0x43EDB88C4B80FDD2ADFF2412A7BEBF9DF42CB40E
OPTIMISM_PORTAL: 0x49048044D57E1C92A77F79988D21FA8FAF74E97E
KAILUA_GAME_TYPE: 1337
Make sure that your FPVM_IMAGE_ID
matches the value above.
This value determines the exact program used to prove faults.
If your RISC_ZERO_VERIFIER
value is blank, this means that your rollup might be deployed on a base layer that does
not have a deployed RISC Zero zkVM verifier contract.
This means you might have to deploy your own verifier.
Always revise the RISC Zero documentation
to double-check verifier availability.
Once you have these values you'll need to save them for later use during migration.
Telemetry
All Kailua binaries and commands support exporting telemetry data to an
OTLP Collector.
The collector endpoint can be specified using the --otlp-collector
parameter, or through specifying the
OTLP_COLLECTOR
environment variable.