Installation

impact protocol installation

Nodes Setup

Installing Dependencies

sudo apt-get update

// install Ubuntu Advanced Packaging Tool
sudo apt install build-essential
sudo apt install --assume-yes git clang curl libssl-dev protobuf-compiler

// setup rust
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh

// refresh current shell
source $HOME/.cargo/env

// verify and check your rust installed version
rustc --version

// configure rust to use latest stable version
rustup default stable
rustup update

// Verify the configuration of your development environment
rustup show
rustup +nightly show

Use Screen

// create new screen
screen -S impact

Build Impact Nodes

// Clone impact protocol repository
git clone https://github.com/GlobalBoost/impactprotocol

// go to the folder
cd impactprotocol

// build the node
cargo build --release

Once the build is done in the above step, run the below command to generate the mining key

./target/release/impact generate-mining-key --chain=impact-testnet

make sure you save the text shown after generating mining key using code above.

Import your mining key with your own seed (make sure you have create wallet using polkadot{js} chrome/firefox extension and fill it with some tokens)

./target/release/impact import-mining-key "<replace_your_seed_phrase>" \--base-path /tmp/impactnode \--chain=impact-testnet

Input your key

./target/release/impact key insert \
  --base-path ~/.impactnode01 \
  --chain=impact-testnet \
  --scheme Ed25519 \
  --suri "CHANGE_THIS_WITH_YOUR_SEED_PHRASE//Alyce///impact" \
  --password-interactive \
  --key-type gran
./target/release/impact key insert \
  --base-path ~/.impactnode01 \
  --chain=impact-testnet \
  --scheme Sr25519 \
  --suri "CHANGE_THIS_WITH_YOUR_SEED_PHRASE//Alyce///impact" \
  --password-interactive \
  --key-type imon
./target/release/impact key insert \
  --base-path ~/.impactnode01 \
  --chain=impact-testnet \
  --scheme Sr25519 \
  --suri "CHANGE_THIS_WITH_YOUR_SEED_PHRASE//Alyce///impact" \
  --password-interactive \
  --key-type auth

Run your nodes (without auto restart)

// run nodes
./target/release/impact \
--base-path /tmp/impactnode \
--chain=impact-testnet \
--port 30333 \
--ws-port 9945 \
--ws-external \
--rpc-cors=all \
--rpc-port 9933 \
--rpc-external \
--telemetry-url "wss://telemetry.polkadot.io/submit/ 0" \
--validator \
--author "YOUR_GENERATED_KEY_FROM_PREVIOUS_STEP" \
--rpc-methods Unsafe \
--name YOUR_NODES_NAME \
--password-interactive

Run your nodes with systemctl (with auto restart if crashed)

sudo tee /etc/systemd/system/impact.service > /dev/null << EOF
[Unit]
Description=Impact Protocol Node
After=network-online.target

[Service]
User=$USER
Restart=on-failure
RestartSec=10
ExecStart=/root/impactprotocol/target/release/./impact \
--base-path /tmp/impactnode \
--chain=impact-testnet \
--port 30333 \
--ws-port 9945 \
--ws-external \
--rpc-cors=all \
--rpc-port 9933 \
--telemetry-url "wss://telemetry.polkadot.io/submit/ 0" \
--validator \
--author "YOUR_GENERATED_KEY_FROM_PREVIOUS_STEP" \
--rpc-methods Unsafe \
--name "YOUR_NODES_NAME" 

[Install]
WantedBy=multi-user.target
EOF
// for running nodes with systemctl
sudo systemctl daemon-reload
sudo systemctl start impact

//check status
sudo systemctl status impact

//restart service
sudo systemctl restart impact

//stop service
sudo systemctl stop impact


//check logs
journalctl -fu impact -o cat

Minimize the screen

// minimize screen
# use your keyboard: CTRL+A+D

Validator Setup

To create author rotate key, use command below

curl -H "Content-Type: application/json" -d'{"id":1, "jsonrpc":"2.0", "method": "author_rotateKeys", "params":[ ]}' http://localhost:9933

Get the minimum required stake of tokens for testnet (if you're running testnet) from SIGNAL group or impact-protocol discord

Create another account (wallet) as the controller account to manage the stash account. Go to the polkadotjs chrome extension and make create account, and make sure you save the seed phrase in a secure place. Fund the controller account as well using the above group

Head over to the polkadot explorer and click the staking button under the Network tab.

Once in staking go to accounts and you will see the nominator and validator button as shown below, first lets discuss about validator

Click on the validator and select the account which you want to be stash and controller account as shown in the picture below

Now click next, enter the keys you generated in step 2 above. You can select whether you want to be nominated and set a commission percentage. Now click bond and validate and then submit button. Shown below

Once done you should see your validator in the waiting to become as validator

You can check your nodes on https://telemetry.polkadot.io/#list/0x1133ca761f24222cb0811f34641dba07acd88c77bd9f30a23a99c2cba233cb91

Last updated