diff --git a/TS3Monitor b/TS3Monitor index 4b1cbe5..ca1086e 100755 --- a/TS3Monitor +++ b/TS3Monitor @@ -14,8 +14,8 @@ # Donations: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=7ZRXLSC2UBVWE # -SCRIPT_VERSION="1.1.0" -LAST_EDIT_DATE="2017-05-04" +SCRIPT_VERSION="1.2.0" +LAST_EDIT_DATE="2017-05-15" # DO NOT REMOVE OR CHANGE SOFTWARE_ABOUT="This script will check the status of your TeamSpeak 3 or TSDNS server instance and if it has crashed, it will try to restart it." @@ -69,7 +69,7 @@ function clearTerminalScreen() { # Return: 0:boolean or 1:boolean function checkConsistency() { CHKSUM=$(grep -v "ORIGIN=" "$0" | head -400 | sha256sum | cut -d " " -f 1) - ORIGIN="cda2c924ca9940f188d5be48b8906f21a6416b1ad3a48959e6c667ba6bb63644" + ORIGIN="b37c05adc6ef73304ede0ffdfab1b9a0d52ae4dfa2a8069da129ed95c1b6a514" if [[ "$CHKSUM" == "$ORIGIN" ]]; then return 0; diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 867498d..ed94b8f 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -23,6 +23,12 @@ Hotfix | Important fix for one more issues, which causes a not (correct) working ## Releases +### Version 1.2.0 (2017-05-15) + + * Cronjobs: The script will now check hourly for a new version + * If the TS3 server was started, the script logged two lines; it will now only log the first line + * Removed colon from variable 'TXT_SELF_TEST_TS3UPDATESCRIPT_RELEASED' + ### Version 1.1.0 (2017-05-04) * One translation for de_DE was missing diff --git a/fncs/30_script.fnc b/fncs/30_script.fnc index 28af04a..fd73213 100755 --- a/fncs/30_script.fnc +++ b/fncs/30_script.fnc @@ -176,7 +176,7 @@ function writeAndAppendLog() { LOG_FILE_PATH="/var/log/ts3tools" LOG_FILE_NAME="ts3monitor.log" - RESULT="${1}" + RESULT=$(echo "${1}" | head -1) if [[ ! -d ${LOG_FILE_PATH} ]]; then mkdir -p ${LOG_FILE_PATH} diff --git a/fncs/40_cron.fnc b/fncs/40_cron.fnc index 3edc10b..7594b36 100755 --- a/fncs/40_cron.fnc +++ b/fncs/40_cron.fnc @@ -21,7 +21,7 @@ function crond() { echo -en "# TS3Monitor: Cronjob for updating the script\n" >> ${CROND_PATH_FILE}; - echo -e " 45 2 * * * root $(pwd)/$(basename $0) --update-script\n" >> ${CROND_PATH_FILE}; + echo -e " 0 * * * * root $(pwd)/$(basename $0) --update-script\n" >> ${CROND_PATH_FILE}; echo -en "# TS3Monitor: Cronjob(s) for monitoring\n" >> ${CROND_PATH_FILE}; diff --git a/languages/verified/de_DE.conf b/languages/verified/de_DE.conf index e2bfac0..e1f7396 100644 --- a/languages/verified/de_DE.conf +++ b/languages/verified/de_DE.conf @@ -29,7 +29,7 @@ TXT_SELF_TEST_INFO="Fuehre Selbst-Tests als Preventivmassnahme gegen moegliche F TXT_SELF_TEST_CHECK_BASH_COMPLETION="Konnte die TS3Monitor Bash-Vervollstaendigung nicht in /etc/bash_completion.d/ts3updatescript einrichten."; TXT_SELF_TEST_CHECK_CONSISTENCY="Du benutzt eine ungueltige Kopie dieses Skripts. Es wird aufgrund von moeglichen Manipulationen durch Hacker NICHT empfohlen, diese Version zu verwenden."; TXT_SELF_TEST_CONNECTIVITY="Konnte einen oder mehrere benoetigte Server fuer den Update-Prozess nicht erreichen. Entweder liegt ein Problem mit der Internetverbindung oder der Webseite selbst vor..."; -TXT_SELF_TEST_TS3UPDATESCRIPT_RELEASED="Bitte aktualisiere das Skript durch den nachfolgenden Befehl auf die aktuellste Version:"; +TXT_SELF_TEST_TS3UPDATESCRIPT_RELEASED="Bitte aktualisiere das Skript durch den nachfolgenden Befehl auf die aktuellste Version"; TXT_SELF_TEST_DETECTION_FAILED="Fehler beim identifizieren der aktuellen Version des TS3Monitor. Bitte ueberpruefe dies manuell: https://github.com/TS3Tools/TS3Monitor"; TXT_SELF_TEST_SCRIPT_SUPPORT="Dein System wird nicht (vollstaendig) von diesem Skript unterstuetzt. Lasse uns bitte wissen, wo wir dein taegliches Cronjob Verzeichnis finden koennen, sodass wir das Skript optimieren koennen."; TXT_SELF_TEST_ADMINISTRATOR_EMAIL="Setze bitte deine eigene Administrator E-Mail Adresse in 'configs/config.all'!"; diff --git a/languages/verified/en_US.conf b/languages/verified/en_US.conf index b2c8c7e..68e31b5 100644 --- a/languages/verified/en_US.conf +++ b/languages/verified/en_US.conf @@ -29,7 +29,7 @@ TXT_SELF_TEST_INFO="Performing self-tests as preventive measures against possibl TXT_SELF_TEST_CHECK_BASH_COMPLETION="Could not set up TS3Monitor bash-completion in /etc/bash_completion.d/ts3updatescript."; TXT_SELF_TEST_CHECK_CONSISTENCY="You are using an invalid copy of this script. It is not recommend to use this in case of hackers may have manipulated it to their advantage."; TXT_SELF_TEST_CONNECTIVITY="Could not reach one or more needed remote servers for update process. Your internet connectivity or the website self is may down..."; -TXT_SELF_TEST_TS3MONITOR_RELEASED="Please update this script to the latest version by using the following command:" +TXT_SELF_TEST_TS3MONITOR_RELEASED="Please update this script to the latest version by using the following command" TXT_SELF_TEST_DETECTION_FAILED="Could not detect version of latest TS3Monitor. Please check manually for a newer version: https://github.com/TS3Tools/TS3Monitor"; TXT_SELF_TEST_SCRIPT_SUPPORT="Your system is not (fully) supported by this script. Please let us know, where we can find your daily cronjob path, that we can improve the script for you."; TXT_SELF_TEST_ADMINISTRATOR_EMAIL="Please set your own administrator eMail in 'configs/config.all'!";