🐳Docker

Authors: [man4ela | catapulta.eth]

System Requirements

CPU
OS
RAM
DISK

4-Core CPU

Debian 12/Ubuntu 22.04

=> 8 GB RAM

250 GB+

(SSD or NVMe)

Starknet Pathfinder full node has a size of 168GB on April 10th, 2025

Before you start, make sure that you have your own synced Ethereum mainnet L1 RPC URL ready with WS port enabled

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 Starknet directory

Create .env file

Paste the following into the file.

Ctrl + x and y to save file

Launch Starknet full node

Paste the following into the docker-compose.yml:

Monitor Logs

Use docker logs to monitor your starknet node. The -f flag ensures you are following the log output

Once your Pathfinder Starknet node starts syncing, the logs are expected to look like this:

1. Check the Chain ID

This confirms which Starknet network the node is connected to:

Expected Response:

Network
Chain ID (Hex)
Chain ID (Decoded)

Mainnet

0x534e5f4d41494e

SN_MAIN

2. Check the Latest Block Number

This ensures that your node is syncing correctly and producing up-to-date data.

Expected Response:

The value returned in resultfield indicates a current block number and should increase over time, confirming that your node is syncing properly.

References

Last updated

Was this helpful?