Best practice is to run node software on an isolated unprivileged user. We'll create the kuji user in this guide; if your username is different change it wherever it appears.
sudo useradd -m -s /bin/bash kuji
Install Golang
Download go and extract go 1.20.8
# remove old go version
sudo rm -rvf /usr/local/go/
# download and install recent go version
curl -fsSL https://golang.org/dl/go1.20.8.linux-amd64.tar.gz | sudo tar -xzC /usr/local
# remove unneeded installer
rm go1.20.8.linux-amd64.tar.gz
# source go
cat <<EOF >> ~/.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 ~/.profile
go version
Build node binary
Login as kuji(skip if you already did)
sudo su -l kuji
Download the project code and checkout to mainnet branch
Set the chain-id. This will save it in client.toml so you won't need --chain-id again.
kujirad config chain-id kaiyo-1
Set some defaults in config.toml and app.toml.
sed -i 's/^timeout_commit =.*/timeout_commit = "1500ms"/' $HOME/.kujira/config/config.toml
sed -i "s/^minimum-gas-prices *=.*/minimum-gas-prices = \"0.00119ukuji,0.00150ibc\/295548A78785A1007F232DE286149A6FF512F180AF5657780FC89C009E2C348F,0.000125ibc\/27394FB092D2ECCD56123C74F36E4C1F926001CEADA9CA97EA622B25F41E5EB2,0.00126ibc\/47BD209179859CDE4A2806763D7189B6E6FE13A17880FE2B42DE1E6C1E329E23,0.00652ibc\/3607EB5B5E64DD1C0E12E07F077FF470D5BC4706AFCBC98FE1BA960E5AE4CE07,617283951ibc\/F3AA7EF362EC5E791FE78A0F4CCC69FEE1F9A7485EB1A8CAB3F6601C00522F10,0.000288ibc\/EFF323CC632EC4F747C61BCE238A758EFDB7699C3226565F7C20DA06509D59A5,5ibc\/DA59C009A0B3B95E0549E6BF7B075C8239285989FF457A8EDDBB56F10B2A6986,0.00137ibc\/A358D7F19237777AF6D8AD0E0F53268F8B18AE8A53ED318095C14D6D7F3B2DB5,0.0488ibc\/4F393C3FCA4190C0A6756CE7F6D897D5D1BE57D6CCB80D0BC87393566A7B6602,78492936ibc\/004EBF085BBED1029326D56BE8A2E67C08CECE670A94AC1947DF413EF5130EB2,964351ibc\/1B38805B1C75352B28169284F96DF56BDEBD9E8FAC005BDCC8CF0378C82AA8E7\"/;" $HOME/.kujira/config/app.toml
(Optional) Configure some seeds. This will help your node find peers.
sed -i 's/^seeds =.*/seeds = "63158c2af0d639d8105a8e6ca2c53dc243dd156f@seed.kujira.mintserve.org:31897,ade4d8bc8cbe014af6ebdf3cb7b1e9ad36f412c0@seeds.polkachu.com:18656"/' $HOME/.kujira/config/config.toml
Start the node
The node is now ready to go.
(Optional) State-sync if you want a head start over syncing from scratch.
Start syncing blocks
kujiradstart
And then watch a fair amount of log messages while your node is catching up. After making sure that it works, it's time to install it as a system level service so it always starts with the machine.
Register the node as a service
A systemd service will keep kujirad running in the background and restart it if it stops.
Create the service file with sudo using your favorite text editor in /etc/systemd/system/kujirad.service .