Skip to content

Latest commit

 

History

History
29 lines (28 loc) · 799 Bytes

README.md

File metadata and controls

29 lines (28 loc) · 799 Bytes

xxtips

Scripts for automate XX node and gateway restarts

Installation

  1. Create telegram bot and get Api Token (via @BotFather in telegram)
  2. Send to your new bot command /start
  3. Clone repo to your node and gateway
cd $HOME && git clone -v https://github.com/ama31337/xxtips.git
  1. Edit Send_msg_toTelBot.sh with your bot API and your telegram id on both machines
  2. Edit online_check.sh with your node URL
  3. Add your user to sudoers to execute node restart w/o password prompt
sudo echo "$USER  ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers
  1. Run script to create crontab tasks on node
cd $HOME/xxtips/scripts && ./add_to_cron_node.sh

and on gateway

cd $HOME/xxtips/scripts && ./add_to_cron_gateway.sh
  1. Check crontab
crontab -l
  1. Done