installation

Installation

The complete infrastructure for cross-chain smart contracts, applications, and modular functionality.

Chain ID: sgenet-1 | Latest Version Tag: v1.1.1 | Wasm: OFF

Chain explorer

https://ping.pub/sge

Public endpoints

Peering

seed-node

6a727128f427d166d90a1185c7965b178235aaee@rpc.sge.nodestake.top:666,e752327338c0141b946ec54f85d51f450c4ad643@46.250.237.163:26656

Installation

Chain ID: sgenet-1 | Latest Version Tag: v1.1.1 |

Install dependencies

Update system and install build tools

sudo apt -q update
sudo apt -qy install curl git jq lz4 build-essential tmux libgmp3-dev flex bison
sudo apt -qy upgrade

Install Go

rm -rf $HOME/go
sudo rm -rf /usr/local/go
cd $HOME
curl https://dl.google.com/go/go1.19.5.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

Download and build binaries

# Clone project repository
cd $HOME
rm -rf sge
git clone https://github.com/sge-network/sge
cd sge
git checkout v1.1.1
make install
sged version

Initialize Node & Genesis

sged init NodeName --chain-id=sgenet-1

Download Genesis

curl -Ls wget https://offellnode.s3.ap-southeast-1.amazonaws.com/sge/genesis.json > $HOME/.stchaind/config/genesis.json 

Create a service

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

Initialize the node

# Set node configuration
sged config chain-id sgenet-1
sged config keyring-backend file

# Add seeds
sed -i -e "s|^seeds *=.*|seeds = \"6a727128f427d166d90a1185c7965b178235aaee@rpc.sge.nodestake.top:666,e752327338c0141b946ec54f85d51f450c4ad643@46.250.237.163:26656\"|" $HOME/.sge/config/config.toml

# Set minimfum gas price
sed -i -e "s|^minimum-gas-prices *=.*|minimum-gas-prices = \"1000000000wei\"|" $HOME/.sge/config/app.toml

# Set pruning
sed -i \
  -e 's|^pruning *=.*|pruning = "custom"|' \
  -e 's|^pruning-keep-recent *=.*|pruning-keep-recent = "100"|' \
  -e 's|^pruning-keep-every *=.*|pruning-keep-every = "0"|' \
  -e 's|^pruning-interval *=.*|pruning-interval = "19"|' \
  $HOME/.sge/config/app.toml

Start service and check the logs

sudo systemctl start sged && sudo journalctl -u sged -f --no-hostname -o cat

Last updated