Create Validator

Local Private Chain

Initilize the chain:

$MONIKER=<your validator name>

SLCd init $MONIKER --chain-id SLC 

The ~/.SLC folder has the following structure:


.                                   # ~/.simapp
  |- data                           # Contains the databases used by the node.
  |- config/
      |- app.toml                   # Application-related configuration file.
      |- config.toml                # Tendermint-related configuration file.
      |- genesis.json               # The genesis file.
      |- node_key.json              # Private key to use for node authentication in the p2p protocol.
      |- priv_validator_key.json    # Private key to use as a validator in the consensus protocol.
#

Create Account:

SLCd keys add <validator name>

Now your can see your account address and private key, write down the keys in somewhere safe.

Add Account To Genesis:

$validator1=$(/SLCd keys show validator1 -a)

SLCd add-genesis-account $validator1 100000000000000000000uswp

SLCd gentx validator1 10000000000uswp --chain-id SLC

SLCd collect-gentxs

Start Chain

SLCd start

If you have done this correctly, you can see blocks are producing.

Join Network

Download genesis file and address book

Address book is a list of peers for validator to dial in order to join network succesfully

Obtain Genesis file and addressbook:

wget -O genesis.json https://raw.githubusercontent.com/SwapLandExchange/chain-releases/main/genesis.json --inet4-only


wget -O addrbook.json https://raw.githubusercontent.com/SwapLandExchange/chain-releases/main/addrbook.json --inet4-only

Move genesis and addressbook under ~/.SLC/config

mv genesis.json ~/.SLC/config

mv addrbook.json ~/.SLC/config

Last updated

Was this helpful?