63 changed files with 127 additions and 24 deletions
@ -0,0 +1,35 @@ |
|||||
|
#!/bin/bash |
||||
|
# LGSM fn_check function |
||||
|
# Author: Daniel Gibbs |
||||
|
# Website: http://gameservermanagers.com |
||||
|
lgsm_version="201215" |
||||
|
|
||||
|
# Description: Overall function for managing checks. |
||||
|
# Runs checks that will either halt on or fix an issue. |
||||
|
|
||||
|
fn_module_compare() { |
||||
|
local e |
||||
|
for e in "${@:2}"; do [[ "$e" == "$1" ]] && return 0; done |
||||
|
return 1 |
||||
|
} |
||||
|
|
||||
|
|
||||
|
check_root.sh |
||||
|
|
||||
|
if [ "${module}" != "install" ]; then |
||||
|
check_executable.sh |
||||
|
fi |
||||
|
|
||||
|
no_check_logs=( details install map-compressor) |
||||
|
fn_module_compare "${module}" "${no_check_logs[@]}" |
||||
|
if [ $? != 0 ]; then |
||||
|
fn_check_logs |
||||
|
fi |
||||
|
|
||||
|
|
||||
|
fn_check_ip |
||||
|
fn_check_steamcmd |
||||
|
fn_check_steamuser |
||||
|
fn_check_tmux |
||||
|
|
||||
|
fn_check_ts3status # may need to move out of checks |
@ -1,5 +1,5 @@ |
|||||
#!/bin/bash |
#!/bin/bash |
||||
# LGSM fn_check_root function |
# LGSM check_root.sh function |
||||
# Author: Daniel Gibbs |
# Author: Daniel Gibbs |
||||
# Website: http://gameservermanagers.com |
# Website: http://gameservermanagers.com |
||||
lgsm_version="061115" |
lgsm_version="061115" |
@ -0,0 +1,68 @@ |
|||||
|
#!/bin/bash |
||||
|
# LGSM fn_debug function |
||||
|
# Author: Daniel Gibbs |
||||
|
# Website: http://gameservermanagers.com |
||||
|
lgsm_version="061115" |
||||
|
|
||||
|
# Description: Runs the server without tmux. Runs direct from the terminal. |
||||
|
|
||||
|
local modulename="Debug" |
||||
|
check_root.sh |
||||
|
fn_check_systemdir |
||||
|
fn_check_ip |
||||
|
fn_check_logs |
||||
|
fn_details_distro |
||||
|
fn_parms |
||||
|
echo "" |
||||
|
echo "${gamename} Debug" |
||||
|
echo "============================" |
||||
|
echo "" |
||||
|
echo -e "Distro: ${os}" |
||||
|
echo -e "Arch: ${arch}" |
||||
|
echo -e "Kernel: ${kernel}" |
||||
|
echo -e "Hostname: $HOSTNAME" |
||||
|
echo "" |
||||
|
echo "Start parameters:" |
||||
|
if [ "${engine}" == "source" ]||[ "${engine}" == "goldsource" ]; then |
||||
|
echo "${executable} ${parms} -debug" |
||||
|
else |
||||
|
echo "${executable} ${parms}" |
||||
|
fi |
||||
|
echo "" |
||||
|
echo -e "Use for identifying server issues only!" |
||||
|
echo -e "Press CTRL+c to drop out of debug mode." |
||||
|
fn_printwarningnl "If ${servicename} is already running it will be stopped." |
||||
|
echo "" |
||||
|
while true; do |
||||
|
read -e -i "y" -p "Continue? [Y/n]" yn |
||||
|
case $yn in |
||||
|
[Yy]* ) break;; |
||||
|
[Nn]* ) echo Exiting; return;; |
||||
|
* ) echo "Please answer yes or no.";; |
||||
|
esac |
||||
|
done |
||||
|
fn_scriptlog "Starting debug" |
||||
|
fn_printinfonl "Stopping any running servers" |
||||
|
fn_scriptlog "Stopping any running servers" |
||||
|
sleep 1 |
||||
|
fn_stop |
||||
|
fn_printdots "Starting debug" |
||||
|
sleep 1 |
||||
|
fn_printok "Starting debug" |
||||
|
fn_scriptlog "Started debug" |
||||
|
sleep 1 |
||||
|
echo -en "\n" |
||||
|
cd "${executabledir}" |
||||
|
if [ "${engine}" == "source" ]||[ "${engine}" == "goldsource" ]; then |
||||
|
if [ "${gamename}" == "Counter Strike: Global Offensive" ]; then |
||||
|
startfix=1 |
||||
|
fn_csgofix |
||||
|
elif [ "${gamename}" == "Insurgency" ]; then |
||||
|
fn_insfix |
||||
|
elif [ "${gamename}" == "ARMA 3" ]; then |
||||
|
fn_arma3fix |
||||
|
fi |
||||
|
${executable} ${parms} -debug |
||||
|
else |
||||
|
${executable} ${parms} |
||||
|
fi |
Loading…
Reference in new issue