Setup Validator Node

This guide will walk you through setting up a validator node on the Ditto Network. You can choose between running the node directly on your system or using Docker.

Systemd Unit Setup

All commands in this section should be executed as the root user.

Prerequisites

  • Linux debian-based
  • Root access to your system

To install node run follow command:

curl -s https://raw.githubusercontent.com/dittonetwork/kepler/refs/heads/develop/scripts/setup-validator.sh | sudo bash

To create a dedicated kepler user (recommended):

  1. Create user:
sudo adduser kepler
  1. Grant sudo:
sudo usermod -aG sudo kepler
  1. Switch to user:
su - kepler
  1. Then run this script with sudo

This script sets up a Kepler validator node on your system. It:

  1. Downloads and installs the keplerd binary
  2. Initializes the node configuration in your home directory
  3. Configures the node with proper gas prices and seeds
  4. Sets your private validator key
  5. Downloads the genesis file
  6. Sets up and starts a systemd service

If you already have a node configured, it will ask before reinitializing. The script must be run with sudo to install the binary and service.

Running as a Docker Container

Prerequisites

  • Docker installed
  • Docker Compose installed

Configuration

  1. Create the working directory structure:
mkdir -p /home/testnet
cd /home/testnet
  1. Create a temporary container to generate configuration:
docker run --rm -v $(pwd)/config:/app/config/config -v $(pwd)/data:/app/config/data ghcr.io/dittonetwork/kepler:{{TAG}} /app/kepler init "kepler" --chain-id testnet --home /app/config
  1. Set up your validator key in config/priv_validator_key.json

  2. Configure ./config/app.toml:

minimum-gas-prices = "0.000025ditto"
  1. Configure ./config/config.toml:
seeds = "66a5fca8a6a7239e0e0afb8b20938bbe555f5c53@espio.testnet.dittonetwork.io:26666,7fd82c652c04213ba6cfff116ffc92dc7728fd51@vector.testnet.dittonetwork.io:26676"
  1. Download the genesis file:
curl -s http://espio.testnet.dittonetwork.io:26667/genesis | jq '.result.genesis' > ./config/genesis.json
  1. Create docker-compose.yml:
services:
  dittonetwork:
    container_name: dittonetwork
    image: ghcr.io/dittonetwork/kepler:{{TAG}}
    network_mode: host
    volumes:
      - ./config:/app/config/config
      - ./data:/app/config/data
    restart: always
  1. Start the node:
docker compose up -d
  1. Monitor the logs:
docker compose logs -f

Checking Synchronization Status

To verify your node’s synchronization status, run:

curl -s http://localhost:26657/status | jq .result.sync_info