🐳Docker

Author: Godwin

System Requirements

CPU

OS

RAM

DISK

8 Cores (Fastest per core speed)

Debian 12/Ubuntu 22.04

16 GB

2TB+ (SSD or NVME preffered)

Moonriver tracing node has a size of 1.8TB on January 28, 2025

Run a tracing node

Pre-Requisites

sudo apt update -y && sudo apt upgrade -y && sudo apt autoremove -y

sudo apt install -y wget curl screen git ufw

Setting up Firewall

sudo ufw default deny incoming
sudo ufw default allow outgoing

sudo ufw allow 22/tcp
sudo ufw allow 80
sudo ufw allow 443

Enable Firewall

Install Docker

Run this command to remove any conflicting docker

Add Docker's official GPG key:

Add the repository to ppt sources:

Install docker

Setting up a domain name to access RPC

Get the IP address of the host machine, you can use the following command in a terminal or command prompt.

Set an A record for a domain, you need to access the domain's DNS settings and create an A record that points to the IP address of the host machine. This configuration allows users to reach your domain by resolving the domain name to the specific IP address associated with your host machine.

Create Moonriver directory

The first command, mkdir moonriver, will create a new directory named moonriver in the current location. The second command, cd moonriver, will change your current working directory to the newly created base directory. Now you are inside the base directory and can start storing docker-compose and related files in it.

Create .env file

Paste the following into the file.

Ctrl + x and y to save file

Make Database directory and set necessary permissions

Create a directory for WASM overrides:

Create docker-compose.yml

Instead of the standard moonbeamfoundation/moonbeam docker image, you will use the moonbeamfoundation/moonbeam-tracing image.

The latest supported version can be found on the Docker Hub for the moonbeam-tracing image from these repos: https://hub.docker.com/r/moonbeamfoundation/moonbeam-tracing/tags

Create and paste the following into the docker-compose.yml

Monitor logs for errors

The expected output after successful launch should look like this:

Test Moonriver RPC

You can call the JSON-RPC API methods to confirm the node is running. For example, call eth_syncing to return the synchronization status. It will return the starting, current, and highest block, or false if not synchronizing (or if the head of the chain has been reached)

Replace https://{YOUR_DOMAIN} with actual domain name or host ip:

Expected out:

Last updated

Was this helpful?