op-reth and op-node to create a functioning sequencer.
Step 2 of 5: This tutorial builds on Spin up op-deployer. Make sure you’ve completed that first.
op-geth as the execution client; this page now uses op-reth throughout.
What you’ll set up
The sequencer node consists of two core components:op-reth: Execution layer that processes transactions and maintains stateop-node: Consensus layer that orders transactions and creates L2 blocks
- Ordering transactions from users
- Building L2 blocks
- Signing blocks on the P2P network
Software installation
For spinning up a sequencer, we recommend using Docker, as it provides a simpler setup and consistent environment. In this guide, building from source is also provided as an alternative for those who need more control and easier debugging.The versions used in this guide (op-node/v1.19.3 and op-reth/v2.4.0) were the latest releases at the time of writing.
Check the op-node releases and op-reth releases for the current versions, and always read the release notes for compatibility information.
- Use docker
- Build from source
1
Set up directory structure and copy configuration files
If you prefer containerized deployment, you can use the official Docker images, and do the following:
2
Create environment variables file
YOUR_ACTUAL_*) with your real configuration values.3
Make sure your docker application is running
Create a
docker-compose.yml file in the same directory:A few flags worth understanding:
--chain=/workspace/genesis.jsonpoints op-reth at the genesis file generated by op-deployer. Unlike op-geth, op-reth needs no separateinitstep — it initializes its database from the chain spec on first startup.--l2.enginekind=rethtells op-node it is driving a reth-based execution client.--rollup.disable-tx-pool-gossipis the op-reth equivalent of op-geth’s--rollup.disabletxpoolgossip=true.--builder.deadline=2and--builder.interval=100mstune op-reth’s block builder for the 2-second L2 block time (the defaults target Ethereum’s 12-second slots).- op-reth runs as an archive node by default, so there is no
--gcmode=archiveequivalent to set.
4
Start the services
5
Final directory structure
What’s Next?
Great! Your sequencer is running and processing transactions. The next step is to set up the batcher to publish transaction data to L1.Spin up batcher →
Next: Configure and start op-batcher to publish L2 transaction data to L1 for data availability.
Need Help?
- Running op-reth: Running op-reth on OP Stack chains
- op-reth CLI reference: op-reth node command
- Best Practices: Chain Operator Best Practices
- Support: Report an issue or ask a question in the Optimism monorepo