2019-08-10 18:27:01 +03:00
|
|
|
#!/bin/bash
|
2019-07-27 03:12:28 +03:00
|
|
|
|
|
|
|
# When this script is:
|
|
|
|
# * run by crontab, load the settings
|
|
|
|
# * run by install, do not load settings
|
|
|
|
|
2019-08-10 18:27:01 +03:00
|
|
|
# Reload settings and functions for when running standalone
|
2019-08-05 22:49:49 +03:00
|
|
|
. functions.sh
|
2019-08-11 11:27:39 +03:00
|
|
|
. settings.sh
|
2019-07-27 03:12:28 +03:00
|
|
|
|
2019-08-05 22:49:49 +03:00
|
|
|
if ! screen -list | grep -q "$_XMRIG_SCREEN"; then
|
2019-08-11 11:27:39 +03:00
|
|
|
|
|
|
|
# Call functions
|
|
|
|
show_mysettings
|
2019-08-05 22:49:49 +03:00
|
|
|
start_xmrig
|
|
|
|
|
|
|
|
# List screen
|
|
|
|
screen -ls
|
2019-07-27 03:12:28 +03:00
|
|
|
else
|
|
|
|
|
2019-08-05 22:49:49 +03:00
|
|
|
# List screen
|
|
|
|
screen -ls
|
2019-07-27 03:12:28 +03:00
|
|
|
|
2019-08-05 22:49:49 +03:00
|
|
|
fi
|
2019-07-27 03:12:28 +03:00
|
|
|
|
2019-08-10 20:43:18 +03:00
|
|
|
echo "${_GREEN}MINING STARTED${_RESET}"
|
2019-07-27 03:12:28 +03:00
|
|
|
|