88
99# BEWARE: The anti-ddos part will disable http, https and dns ports.
1010
11- VERSION=" 0.1.10"
11+ # This installs latest node 4.3.0.6 and latest 0.0.99 hn version
12+
13+ VERSION=" 0.1.20"
1214
1315create_swap () {
1416 if [ -d /swapfile ]; then
@@ -54,7 +56,7 @@ install_dependencies() {
5456 # apt update -y
5557 # This may be enough,
5658 # apt install ufw unzip ntpdate python3-pip sqlite3 -y
57- apt install ufw unzip ntpdate python3-pip sqlite3 build-essential python3-dev -y
59+ apt install htop ufw unzip ntpdat sqlite3 build-essential python3.7 -dev -y
5860 # ntpdate ntp.ubuntu.com
5961 # apt install ntp -y
6062}
@@ -107,8 +109,8 @@ download_node() {
107109 cd /root/Bismuth
108110 wget https://gist.githubusercontent.com/EggPool/e7ad9baa2b32e4d7d3ba658a40b6d643/raw/934598c7ff815180b913d6549bd2d9688e016855/node_sentinel.py
109111 echo " Installing PIP requirements"
110- pip3 install setuptools
111- pip3 install -r requirements-node.txt
112+ python3.7 -m pip install setuptools ipwhois
113+ python3.7 -m pip install -r requirements-node.txt
112114}
113115
114116download_hypernode () {
@@ -121,8 +123,8 @@ download_hypernode() {
121123 tar -zxf hypernode.tar.gz
122124 cd hypernode
123125 echo " Installing PIP requirements"
124- pip3 install wheel
125- pip3 install -r requirements.txt
126+ python3.7 -m pip install wheel
127+ python3.7 -m pip install -r requirements.txt
126128}
127129
128130
@@ -136,7 +138,7 @@ install_plugin() {
136138start_node () {
137139 echo " Starting node"
138140 cd
139- screen -d -S node -m bash -c " cd Bismuth;python3 node.py" -X quit
141+ screen -d -S node -m bash -c " cd Bismuth;python3.7 node.py" -X quit
140142}
141143
142144wait_ledger () {
@@ -155,21 +157,21 @@ wait_ledger() {
155157check_hypernode () {
156158 echo " Checking Hypernode"
157159 cd /root/hypernode/main
158- python3 hn_check.py
160+ python3.7 hn_check.py
159161}
160162
161163add_cron_jobs () {
162164 # Node sentinel
163165 if ! crontab -l | grep " node_sentinel" ; then
164- (crontab -l ; echo " * * * * * cd /root/Bismuth;python3 node_sentinel.py" ) | crontab -
166+ (crontab -l ; echo " * * * * * cd /root/Bismuth;python3.7 node_sentinel.py" ) | crontab -
165167 fi
166168 # Hypernode sentinel1
167169 if ! crontab -l | grep " cron1.py" ; then
168- (crontab -l ; echo " * * * * * cd /root/hypernode/crontab;python3 cron1.py" ) | crontab -
170+ (crontab -l ; echo " * * * * * cd /root/hypernode/crontab;python3.7 cron1.py" ) | crontab -
169171 fi
170172 # Hypernode sentinel5
171173 if ! crontab -l | grep " cron5.py" ; then
172- (crontab -l ; echo " */5 * * * * cd /root/hypernode/crontab;python3 cron5.py" ) | crontab -
174+ (crontab -l ; echo " */5 * * * * cd /root/hypernode/crontab;python3.7 cron5.py" ) | crontab -
173175 fi
174176}
175177
0 commit comments