LOGOSNODOS
  • LOGOSNODOS
  • 🖥️Mainnet Node
    • Avail Network
      • ▶️Installation
      • ▶️Staking / Bonding
    • BlockX
      • ▶️Installation
      • ▶️Cheat Sheet
    • Muon Network
      • ▶️Installation
      • ▶️Troubleshooting
    • RaiblocksOne
      • ▶️Installation
      • ▶️Cheat Sheet
    • SGE Network
      • ▶️Installation
      • ▶️Cheat Sheet
    • Quicksilver Protocol
      • ▶️Installation
      • ▶️Cheat Sheet
  • 🛠️TESTNET NODE
    • 0gchain
      • ▶️Installation
      • ▶️Cheat Sheet
    • Airchains
      • ▶️Installation
      • ▶️Cheat Sheet
    • Avail Network
      • ▶️Installation
      • ▶️Challenge Set Identity
      • ▶️Challenge Add Pool
    • Cortensor
      • ▶️Staking and Funding
      • ▶️Installation
      • ▶️Node Management
      • ▶️Monitoring
    • CrossFi
      • ▶️Installation
      • ▶️Cheat Sheet
    • Juneo Network
      • ▶️Installation
      • ▶️Create Supernet
      • ▶️Deploy a VM
    • Namada
      • ▶️Installation
      • ▶️Cheat Sheet
    • Pryzm
      • ▶️Installation
      • ▶️Cheat Sheet
    • Quicksilver Protocol
      • ▶️Installation
      • ▶️Cheat Sheet
    • Swisstronik
      • ▶️Installation
      • ▶️Cheat Sheet
    • Symphony
      • ▶️Installation
      • ▶️Cheat Sheet
  • ⛑️Solidity Compiler
    • Hardhat
      • ▶️Installation
      • ▶️Setup Hardhat on Swisstronik Network
      • ▶️Write and compile the smart contract
      • ▶️Deploy the smart contract
      • ▶️Interact with the contract-Transaction
      • ▶️Interact with the contract-Call
      • ▶️Crafts and Mint Token ERC20
      • ▶️PERC20 (Private ERC20) Deploy, Mint and Transfer.
      • ▶️JSON RPC Call using ETH getStorage
Powered by GitBook
On this page
  • Installation
  • Install dependencies

Was this helpful?

  1. TESTNET NODE
  2. Swisstronik

Installation

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

Last updated 1 year ago

Was this helpful?

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

Before installing the node you should enable SGX and confirm your system ready by installing SGX and obtain masterkey :

Installation

Install dependencies

Setting up variable

echo "export SWISSTRONIK_CHAIN_ID=swisstronik_1291-1" >> $HOME/.bash_profile
source $HOME/.bash_profile

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.21.4.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

cd $HOME
wget https://github.com/SigmaGmbH/swisstronik-chain/releases/download/v1.0.1/swisstronikd.deb.zip 
unzip swisstronikd.deb.zip  
dpkg -i swisstronik_1.0.1-updated-binaries_amd64.deb
swisstronikd version

Change your moniker

swisstronikd init <Moniker> --chain-id=swisstronik_1291-1

Download Genesis

curl https://rpc.testnet.swisstronik.com/genesis? | jq ".result.genesis" > ~/.swisstronik/config/genesis.json

Set the gas prices

sed -i.bak -e "s/^minimum-gas-prices *=.*/minimum-gas-prices = \"7uswtr\"/;" ~/.swisstronik/config/app.toml
external_address=$(wget -qO- eth0.me) 
sed -i.bak -e "s/^external_address *=.*/external_address = \"$external_address:26656\"/" $HOME/.swisstronik/config/config.toml
sed -i.bak -e "s/^seeds =.*/seeds = \"$seeds\"/" $HOME/.swisstronik/config/config.toml

Specify prunning option

pruning="custom" && \
pruning_keep_recent="100" && \
pruning_keep_every="0" && \
pruning_interval="10" && \
sed -i -e "s/^pruning *=.*/pruning = \"$pruning\"/" ~/.swisstronik/config/app.toml && \
sed -i -e "s/^pruning-keep-recent *=.*/pruning-keep-recent = \"$pruning_keep_recent\"/" ~/.swisstronik/config/app.toml && \
sed -i -e "s/^pruning-keep-every *=.*/pruning-keep-every = \"$pruning_keep_every\"/" ~/.swisstronik/config/app.toml && \
sed -i -e "s/^pruning-interval *=.*/pruning-interval = \"$pruning_interval\"/" ~/.swisstronik/config/app.toml

Create a service

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

[Service]
User=$USER
ExecStart=$(which swisstronikd) start
Restart=on-failure
RestartSec=3
LimitNOFILE=65535

[Install]
WantedBy=multi-user.target
EOF

sudo systemctl daemon-reload
sudo systemctl enable swisstronikd

Start service and check the logs

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

If you got enclave error you should obtain master key :

mkdir $HOME/.swisstronik-enclave/
sudo cp /usr/lib/enclave.signed.so $HOME/.swisstronik-enclave/
swisstronikd enclave request-master-key rpc.testnet.swisstronik.com:46789
🛠️
▶️
https://swisstronik.gitbook.io/swisstronik-docs/node-setup/setup-sgx/setup-intel-sgx