****


This how-to guides you through the process of setting up a local Arbitrum Nitro dev node, with Stylus support, to help you deploy and test smart contracts written in Solidity or any of the languages supported by Stylus in a fully controlled environment. By following these steps, you'll deploy and run a full development environment on your local machine that includes a Nitro dev node (L2), a dev-mode geth parent chain (L1), and multiple instances with different roles.

Step 1. Install prerequisites****

You'll need docker and docker compose to run your node. Follow the instructions in their site to install them.

Step 2. Clone the nitro-testnode repo****

You'll need the stylus branch.

git clone -b stylus --recurse-submodules <https://github.com/OffchainLabs/nitro-testnode.git> && cd nitro-testnode

Step 3. Run your node****

./test-node.bash --init

Step 4. Successive runs****

To relaunch the node after the first installation, run the following command.

./test-node.bash

CLEAR LOCAL DATA

Note that running with the --init flag will clear all chain data and redeploy!

Rollup contract addresses and chain configuration****

You can obtain the rollup chain configuration by running the following command. The chain configuration also includes the addresses of the core contracts.

docker exec nitro-testnode-sequencer-1 cat /config/l2_chain_info.json

You can find other available configuration files by running:

docker exec nitro-testnode-sequencer-1 ls /config