2019-08-10 18:27:01 +03:00
|
|
|
#!/bin/bash
|
2019-07-27 03:12:28 +03:00
|
|
|
|
2019-08-11 16:58:07 +03:00
|
|
|
echo "${_GREEN}MINING STARTED${_RESET}"
|
|
|
|
|
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
|
2019-08-11 17:00:25 +03:00
|
|
|
show_settings
|
2019-08-11 17:22:01 +03:00
|
|
|
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-11 16:58:07 +03:00
|
|
|
echo "${_CYAN}MINING RUNNING${_RESET}"
|
|
|
|
echo "${_YELLOW} The process is running in a screen session."
|
2019-08-11 17:05:12 +03:00
|
|
|
echo "${_YELLOW} The screen session is named:${_RESET} $_XMRIG_SCREEN"
|
|
|
|
echo "${_YELLOW} Command to view process:${_RESET} screen -r $_XMRIG_SCREEN"
|
2019-08-11 16:58:07 +03:00
|
|
|
echo "${_MAGENTA} ENJOY!!!${_RESET}"
|
2019-07-27 03:12:28 +03:00
|
|
|
|