Mainnet

Chain ID: gitopia | Node Version: v2.0.0

Node Installation Guide

Update system and install build tools

sudo apt update

sudo apt-get install git curl build-essential make jq gcc snapd chrony lz4 tmux unzip bc -y

Install Go

rm -rf $HOME/go
sudo rm -rf /usr/local/go
cd $HOME
curl https://dl.google.com/go/go1.20.1.linux-amd64.tar.gz | sudo tar -C/usr/local -zxvf -
cat <<'EOF' >>$HOME/.profile
export GOROOT=/usr/local/go
export GOPATH=$HOME/go
export GO111MODULE=on
export PATH=$PATH:/usr/local/go/bin:$HOME/go/bin
EOF
source $HOME/.profile
go version

Install Node

cd $HOME

rm -rf gitopia

git clone https://github.com/gitopia/gitopia.git

cd gitopia

git checkout v2.0.0

make install

gitopiad version

Initialize Node

Replace NodeName with your own moniker.

gitopiad init NodeName --chain-id=gitopia

Download Genesis

curl -Ls https://ss.gitopia.nodestake.top/genesis.json > $HOME/.gitopia/config/genesis.json 

Download addrbook

curl -Ls https://ss.gitopia.nodestake.top/addrbook.json > $HOME/.gitopia/config/addrbook.json

Create Service

sudo tee /etc/systemd/system/gitopiad.service > /dev/null <<EOF
[Unit]
Description=gitopiad Daemon
After=network-online.target
[Service]
User=$USER
ExecStart=$(which gitopiad) start
Restart=always
RestartSec=3
LimitNOFILE=65535
[Install]
WantedBy=multi-user.target
EOF
sudo systemctl daemon-reload
sudo systemctl enable gitopiad

Download Snapshot(optional)

SNAP_NAME=$(curl -s https://ss.gitopia.nodestake.top/ | egrep -o ">20.*\.tar.lz4" | tr -d ">")

curl -o - -L https://ss.gitopia.nodestake.top/${SNAP_NAME}  | lz4 -c -d - | tar -x -C $HOME/.gitopia

Launch Node

sudo systemctl restart gitopiad
journalctl -u gitopiad -f

If you have any questions, please reach out to our Discord

 

https://rpc.gitopia.nodestake.top

 

https://api.gitopia.nodestake.top

 

https://grpc.gitopia.nodestake.top:443

https://ss.gitopia.nodestake.top/genesis.json

Download Genesis File

curl -Ls https://ss.gitopia.nodestake.top/genesis.json > $HOME/.gitopia/config/genesis.json 

a74403b9fbf58ba7538e0a9584510c67a0877beb@rpc.gitopia.nodestake.top:666

Set Seed Node

seed="a74403b9fbf58ba7538e0a9584510c67a0877beb@rpc.gitopia.nodestake.top:666"
sed -i.bak -e "s/^seed *=.*/seed = \"$seed\"/" ~/.evmosd/config/config.toml

Restart Node

sudo systemctl restart strided
journalctl -u strided -f

https://ss.gitopia.nodestake.top/addrbook.json

Download Addrbook

curl -Ls https://ss.gitopia.nodestake.top/addrbook.json > $HOME/.gitopia/config/addrbook.json 

Restart Node

sudo systemctl restart gitopiad
journalctl -u gitopiad -f

Set Peers

peers=$(curl -s https://ss.gitopia.nodestake.top/peers.txt)
sed -i.bak -e "s/^persistent_peers *=.*/persistent_peers = \"$peers\"/" ~/.gitopia/config/config.toml

Restart Node

sudo systemctl restart gitopiad
journalctl -u gitopiad -f

Stop Node And Reset

sudo systemctl stop gitopiad

gitopiad tendermint unsafe-reset-all --home ~/.gitopia/ --keep-addr-book

Configure State Sync

SNAP_RPC="https://rpc.gitopia.nodestake.top:443"

LATEST_HEIGHT=$(curl -s $SNAP_RPC/block | jq -r .result.block.header.height); \

BLOCK_HEIGHT=$((LATEST_HEIGHT - 1000)); \

TRUST_HASH=$(curl -s "$SNAP_RPC/block?height=$BLOCK_HEIGHT" | jq -r .result.block_id.hash)

echo $LATEST_HEIGHT $BLOCK_HEIGHT $TRUST_HASH

 

sed -i.bak -E "s|^(enable[[:space:]]+=[[:space:]]+).*$|\1true| ; \

s|^(rpc_servers[[:space:]]+=[[:space:]]+).*$|\1\"$SNAP_RPC,$SNAP_RPC\"| ; \

s|^(trust_height[[:space:]]+=[[:space:]]+).*$|\1$BLOCK_HEIGHT| ; \

s|^(trust_hash[[:space:]]+=[[:space:]]+).*$|\1\"$TRUST_HASH\"| ; \

s|^(seeds[[:space:]]+=[[:space:]]+).*$|\1\"\"|" ~/.gitopia/config/config.toml

more ~/.gitopia/config/config.toml | grep 'rpc_servers'

more ~/.gitopia/config/config.toml | grep 'trust_height'

more ~/.gitopia/config/config.toml | grep 'trust_hash'

Restart Node

sudo systemctl restart gitopiad
journalctl -u gitopiad -f

Install lz4

sudo apt update

sudo apt-get install snapd lz4 -y

Off State Sync

sed -i.bak -E "s|^(enable[[:space:]]+=[[:space:]]+).*$|\1false|" ~/.gitopia/config/config.toml

Stop Node and Reset Date

sudo systemctl stop gitopiad

cp $HOME/.gitopia/data/priv_validator_state.json $HOME/.gitopia/priv_validator_state.json.backup

rm -rf ~/.gitopia/data

gitopiad tendermint unsafe-reset-all --home ~/.gitopia/ --keep-addr-book

Download Snapshot

SNAP_NAME=$(curl -s https://ss.gitopia.nodestake.top/ | egrep -o ">20.*\.tar.lz4" | tr -d ">")

curl -o - -L https://ss.gitopia.nodestake.top/${SNAP_NAME}  | lz4 -c -d - | tar -x -C $HOME/.gitopia

mv $HOME/.gitopia/priv_validator_state.json.backup $HOME/.gitopia/data/priv_validator_state.json

Restart Node

sudo systemctl restart gitopiad
journalctl -u gitopiad -f

If you have any questions, please reach out to our Discord