diff --git a/lgsm/functions/alert.sh b/lgsm/functions/alert.sh index fb914a42f..9fec83369 100644 --- a/lgsm/functions/alert.sh +++ b/lgsm/functions/alert.sh @@ -31,14 +31,22 @@ fn_alert_update(){ alertbody="${servicename} received update" } -if [ "${alert}" == "restart" ]; then +fn_alert_permissions(){ + fn_script_log_info "Sending permissions error alert" + alertsubject="LinuxGSM - Permissions Error - ${servername}" + alertbody="${servicename} has permissions issues." +} + +if [ "${alert}" == "permissions" ]; then + fn_alert_permissions +elif [ "${alert}" == "restart" ]; then fn_alert_restart elif [ "${alert}" == "restartquery" ]; then fn_alert_restart_query -elif [ "${alert}" == "update" ]; then - fn_alert_update elif [ "${alert}" == "test" ]; then fn_alert_test +elif [ "${alert}" == "update" ]; then + fn_alert_update fi if [ "${emailalert}" == "on" ]&&[ -n "${email}" ]; then diff --git a/lgsm/functions/check_permissions.sh b/lgsm/functions/check_permissions.sh index 840cc9864..2a198d3c5 100644 --- a/lgsm/functions/check_permissions.sh +++ b/lgsm/functions/check_permissions.sh @@ -43,8 +43,10 @@ fn_check_ownership(){ } | column -s $'\t' -t | tee -a "${scriptlog}" echo "" - fn_print_information_nl "For more information, please see https://github.com/GameServerManagers/LinuxGSM/wiki/FAQ#-fail--starting-game-server-ownership-issues-found" + fn_print_information_nl "please see https://github.com/GameServerManagers/LinuxGSM/wiki/FAQ#-fail--starting-game-server-ownership-issues-found" fn_script_log "For more information, please see https://github.com/GameServerManagers/LinuxGSM/wiki/FAQ#-fail--starting-game-server-ownership-issues-found" + alert="permissions" + alert.sh core_exit.sh fi }