Set Up Docker Validator

Run a self-hosted Docker validator to perform network upgrades on your L1.

Why Docker?

BuilderHub hosted nodes are convenient, but they don't allow direct access to configuration files. To perform network upgrades (like disabling/enabling precompiles), you need to:

  1. Edit the upgrade.json file in the node's config directory
  2. Restart the node to apply changes

This requires running your own validator with full access to the filesystem.

Important: Your Docker validator will become the primary node for this exercise. Make sure you have Docker installed and running on your machine.

Prerequisites

Before starting, ensure you have:

  • Docker installed and running
  • Your Blockchain ID from the L1 you created earlier
  • Your Subnet ID from the L1 you created earlier

Instructions

Step 1: Launch Docker Validator

Use the tool below to run a self-hosted AvalancheGo node in Docker:

Builder Console

L1 Node Setup with Docker

Configure your node settings, preview the Subnet-EVM chain config, create it on your server, and run Docker to start your L1 node.

Docker Installation

Make sure you have Docker installed on your system. You can use the following commands to install it:

# Install Docker using convenience scriptcurl -fsSL https://get.docker.com -o get-docker.shsudo sh get-docker.shsudo usermod -aG docker $USERnewgrp docker# Test installationdocker run -it --rm hello-world
# Install Dockersudo yum update -ysudo yum install -y dockersudo systemctl start dockersudo systemctl enable dockersudo usermod -aG docker $USERnewgrp docker# Test installationdocker run -it --rm hello-world
# Install Docker using convenience scriptcurl -fsSL https://get.docker.com -o get-docker.shsudo sh get-docker.shsudo usermod -aG docker $USERnewgrp docker# Test installationdocker run -it --rm hello-world
# Install Docker Desktop for Mac# Download from: https://www.docker.com/products/docker-desktop/echo "Please download and install Docker Desktop for Mac from the official Docker website."# After installation, you can test it by running:docker run -it --rm hello-world

If you do not want to use Docker, you can follow the instructions here.

Select L1

Enter the Avalanche Subnet ID of the L1 you want to run a node for

The tool will generate the Docker command with the correct configuration for your L1.

Step 2: Verify the Node is Running

Check that your container is running:

docker ps

You should see a container running AvalancheGo.

Step 3: Verify Bootstrap Status

Open a shell inside your container:

docker exec -it <YOUR_CONTAINER_NAME_OR_ID> sh

Then check if your chain is bootstrapped:

curl -X POST --data '{
  "jsonrpc":"2.0",
  "id":1,
  "method":"info.isBootstrapped",
  "params": {
    "chain":"YOUR_BLOCKCHAIN_ID"
  }
}' -H 'content-type:application/json;' 127.0.0.1:9650/ext/info

Replace YOUR_BLOCKCHAIN_ID with your L1's blockchain ID. You should see:

{"jsonrpc":"2.0","result":{"isBootstrapped":true},"id":1}

Step 4: Connect Core Wallet

Add your L1's RPC to Core Wallet:

  • RPC URL: http://localhost:9650/ext/bc/YOUR_BLOCKCHAIN_ID/rpc
  • Chain ID: Your L1's chain ID

Verify you can see your balance and send transactions.

Expected Output

You should have:

  • A running Docker container with AvalancheGo
  • Your L1 chain bootstrapped and producing blocks
  • Core Wallet connected to your local node

What You Can Now Do

With your own Docker validator, you can:

  • Access the node's config directory at ~/.avalanchego/configs/chains/<BLOCKCHAIN_ID>/
  • Create and modify upgrade.json files
  • Restart the node to apply network upgrades

Next Steps

Now that your Docker validator is running, you'll learn the rules for creating network upgrades.

Is this guide helpful?