July 30
WARDEN: Start Node Guide
This simple guide will help you get your Warden Protocol project node up and running. After reading this guide you will no longer have a question about how to do it!
Hardware Requirement
Install
git clone --depth 1 --branch v0.3.0 https://github.com/warden-protocol/wardenprotocol/
just build
build/wardend init <custom_moniker>
Configure
cd $HOME/.warden/config rm genesis.json wget https://raw.githubusercontent.com/warden-protocol/networks/main/testnets/buenavista/genesis.json
Set the mandatory configuration options:
sed -i 's/minimum-gas-prices = ""/minimum-gas-prices = "0.0025uward"/' app.toml sed -i 's/persistent_peers = ""/persistent_peers = "[email protected]:26656,[email protected]:26656"/' config.toml
Set up the state sync
From this RPC endpoint, you can get the trusted block height and hash:
export SNAP_RPC_SERVERS=" https://rpc.buenavista.wardenprotocol.org:443,https://rpc.buenavista.wardenprotocol.org:443 " export LATEST_HEIGHT=$(curl -s "https://rpc.buenavista.wardenprotocol.org/block" | jq -r .result.block.header.height) export BLOCK_HEIGHT=$((LATEST_HEIGHT - 2000)) export TRUST_HASH=$(curl -s "https://rpc.buenavista.wardenprotocol.org/block?height=$ BLOCK_HEIGHT" | jq -r .result.block_id.hash)
Check that all variables have been set correctly:
echo $LATEST_HEIGHT $BLOCK_HEIGHT $TRUST_HASH # output should be similar to: # 70694 68694 6AF4938885598EA10C0BD493D267EF363B067101B6F81D1210B27EBE0B32FA2A
Add the state sync configuration to your config.toml:
sed -i.bak -E "s|^(enable[[:space:]]+=[[:space:]]+).*$|\1true| ; \ s|^(rpc_servers[[:space:]]+=[[:space:]]+).*$|\1\"$SNAP_RPC_SERVERS\"| ; \ s|^(trust_height[[:space:]]+=[[:space:]]+).*$|\1$BLOCK_HEIGHT| ; \ s|^(trust_hash[[:space:]]+=[[:space:]]+).*$|\1\"$TRUST_HASH\"|" $HOME/.warden/config/config.toml
Start the Node
wardend start