Installation

🖥️System Requirements - OS: Linux - CPU: 4 Core(s) - Memory: 16GB - Storage: 1TB

Install dependencies

sudo apt -q update
sudo apt -qy install curl git jq lz4 build-essential
sudo apt -qy upgrade

Install GO

ver="1.21.3" &&
wget "https://golang.org/dl/go$ver.linux-amd64.tar.gz" &&
sudo rm -rf /usr/local/go &&
sudo tar -C /usr/local -xzf "go$ver.linux-amd64.tar.gz" &&
rm "go$ver.linux-amd64.tar.gz" &&
echo "export PATH=$PATH:/usr/local/go/bin:$HOME/go/bin" >> $HOME/.bash_profile &&
source $HOME/.bash_profile &&
go version

Install with Cosmovisor

ADVANCED ROUTE

Cosmosvisor is a process manager for Cosmos SDK application binaries that monitors the governance module for incoming chain upgrade proposals. If a proposal is approved, cosmosvisor can automatically download the new binary, stop the current one, switch to the new binary, and restart the node with the new binary.

Download and build binaries

Clone Initia repo and build initiad v0.2.14

cd $HOME
git clone https://github.com/initia-labs/initia.git
cd initia
git checkout v0.2.14

Build binaries

make install

Prepare binaries for Cosmovisor

cd $HOME
mkdir -p ~/.initiad/cosmovisor/upgrades/v0.2.14/bin
mv $HOME/go/bin/initiad ~/.initiad/cosmovisor/upgrades/v0.2.14/bin/
sudo ln -s ~/.initiad/cosmovisor/genesis ~/.initiad/cosmovisor/current -f
sudo ln -s ~/.initiad/cosmovisor/current/bin/initiad /usr/local/bin/initiad -f

Download and install Cosmovisor

go install cosmossdk.io/tools/cosmovisor/cmd/cosmovisor@v1.5.0

Run node

Create service

sudo tee /etc/systemd/system/initiad.service > /dev/null << EOF
[Unit]
Description=initia node service
After=network-online.target

[Service]
User=$USER
ExecStart=$(which cosmovisor) run start
Restart=on-failure
RestartSec=10
LimitNOFILE=65535
Environment="DAEMON_HOME=~/.initiad"
Environment="DAEMON_NAME=initiad"
Environment="UNSAFE_SKIP_BACKUP=true"
Environment="PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:~/.initiad/cosmovisor/current/bin"

[Install]
WantedBy=multi-user.target
EOF

Last updated