January 15, 2024

Установка ноды Shardeum

Обновляем сервер

sudo apt update && sudo apt upgrade -y
sudo apt install curl build-essential pkg-config libssl-dev git wget jq make gcc tmux chrony -y
. <(wget -qO- https://raw.githubusercontent.com/SecorD0/utils/main/installers/docker.sh)
apt install docker.io -y
sudo apt install apparmor-profiles
sudo chmod +x /usr/bin/docker-compose
sudo apt install curl build-essential git screen jq pkg-config libssl-dev libclang-dev ca-certificates gnupg lsb-release -y
apt install npm

Запускаем скрипт

cd
screen -S shrd
curl -O https://gitlab.com/shardeum/validator/dashboard/-/raw/main/installer.sh && chmod +x installer.sh && ./installer.sh

Отвечаем на вопросы

  • By running this installer, you agree to allow the Shardeum team to collect this data. (y/n)?: Вписываем y
  • What base directory should the node use (default ~/.shardeum): Жмём Enter
  • Do you want to run the web based Dashboard? (y/n): Вписываем y
  • Set the password to access the Dashboard: вводим ваш пароль
  • Enter the port (1025-65536) to access the web based Dashboard (default 8080): Вписываем 12080
  • If you wish to set an explicit external IP, enter an IPv4 address (default=auto): Жмём Enter
  • To run a validator on the Sphinx network, you will need to open two ports in your firewall.
    This allows p2p commnication between nodes. Enter the first port (1025-65536) for p2p comminucation (default 9001) : Вписываем 9111
  • Enter the second port (1025-65536) for p2p comminucation (default 10001): Вписываем 10111

Открываем порты в фаерволе

ufw allow 22
ufw allow 12080
ufw allow 9111
ufw allow 10111
ufw enable

Запускаем валидатора

cd
cd .shardeum
./shell.sh
operator-cli gui start
operator-cli gui status

Переходим в браузер по ссылке: https://<ваш_IPсервера>:12080 и вводим ваш пароль

Переходим в терминал и запускаем ноду

operator-cli start

Переходим обратно в браузер и обновляем страницу. Если кнопка сменилась на "Stop Node", то вы все сделали верно и нода запущена.

Стейк токенов валидатору

Переходим на страницу вашего валидатора и подключаете кошелек Metamask

Просим токены в дискорде

Выход из скрина CTRL + A + D

Полезные команды

Возврат в скрин

screen -x shrd

Остановка ноды

operator-cli stop

Проверить статус ноды

operator-cli gui status

Для выхода из оболочки используем команду

exit

Удаление ноды

cd ~/.shardeum
./cleanup.sh
cd ~/
rm -rf .shardeum
rm installer.sh