Module 3 - Setting Up OP Geth Node and Block Explorer
In this module, we’ll set up the OP Geth node and block explorer for your L2. The OP Geth node serves as a non-voting RPC node that enables executing Eth L2 transactions.
Overview
Section titled “Overview”Setting up an OP Geth Node requires three services:
- OP Geth: Modified to calculate gas based on required Solana compute
- Rhea: Picks up Eth transactions from OP Geth mempool and submits them to Solana
- Light Client (Proxy): Provides an Ethereum interface to access Solana state
Step 1: Run Docker Containers
Section titled “Step 1: Run Docker Containers”Run the Docker containers in the following order:
1. Light Client (Proxy)
Section titled “1. Light Client (Proxy)”First, airdrop SOLs to the Light Client keypair using Solana Faucet. Get the keypair address:
solana address -k keys/proxy-sender.json
Run the Light Client container:
docker compose up -d proxydocker logs proxy -f
Wait until the logs show “Starting the RPC server at 0.0.0.0:9090”.
2. Geth
Section titled “2. Geth”If you’re setting up your L2 on your local machine, comment out Geth volumes in rome-setup/docker/docker-compose.yml
:
# volumes:# - /etc/letsencrypt/live/${GETH_HOST}/fullchain.pem:/etc/nginx/ssl/selfsigned.crt# - /etc/letsencrypt/live/${GETH_HOST}/privkey.pem:/etc/nginx/ssl/selfsigned.key
If you’re setting up on a remote server, keep these volumes uncommented.
Run the Geth container:
docker compose up -d gethdocker logs geth -f
Wait until the logs show “Server listening at http://localhost:3000”.
3. Rhea
Section titled “3. Rhea”Airdrop SOLs to the Rhea keypair using Solana Faucet. Get the keypair address:
solana address -k keys/rhea-sender.json
Run the Rhea container:
docker compose up -d rheadocker logs rhea -f
Wait until the logs show “Polling: http://geth:8545”.
Step 2: Set Up Block Explorer
Section titled “Step 2: Set Up Block Explorer”Clone the Repository
Section titled “Clone the Repository”If you’re running your L2 on your local machine, clone the local branch:
git clone --branch local https://github.com/rome-labs/romescout.git
If you’re running on a remote server, clone the testnet branch:
git clone --branch testnet https://github.com/rome-labs/romescout.git
Navigate to Docker Compose Directory
Section titled “Navigate to Docker Compose Directory”cd romescout/docker-compose
Update Configuration
Section titled “Update Configuration”If you’re running on a remote server, replace rollup.testnet.romeprotocol.xyz
with your domain in:
romescout/docker-compose/services/nginx.yml
romescout/docker-compose/envs/common-frontend.env
Update Branding
Section titled “Update Branding”Update the following environment variables in the configuration:
NEXT_PUBLIC_NETWORK_NAME=RomeNEXT_PUBLIC_NETWORK_SHORT_NAME=RomeNEXT_PUBLIC_NETWORK_ID=915817419NEXT_PUBLIC_NETWORK_CURRENCY_NAME=RomeNEXT_PUBLIC_NETWORK_CURRENCY_SYMBOL=ROME
NEXT_PUBLIC_NETWORK_LOGO=http://rome-public-assets.s3.us-east-1.amazonaws.com/rome-banner.pngNEXT_PUBLIC_NETWORK_ICON=http://rome-public-assets.s3.us-east-1.amazonaws.com/rome-logo.pngNEXT_PUBLIC_HOMEPAGE_PLATE_TEXT_COLOR=whiteNEXT_PUBLIC_HOMEPAGE_PLATE_BACKGROUND=#5E0A60
Build and Run
Section titled “Build and Run”Remove old data (skip if running for the first time):
sudo rm -rf services/blockscout-db-datasudo rm -rf services/stats-db-data
Build and run the Docker container:
docker-compose up --build -d# docker compose down
Access the Rome Scout Explorer at:
- Local: http://localhost:1000
- Remote: https://rollup.testnet.romeprotocol.xyz:1000 (replace with your domain)