Przeglądaj źródła

Merge branch 'release/190509'

Daniel Gibbs 7 lat temu
rodzic
commit
b0bc79bc47

+ 1 - 8
lgsm/config-default/config-lgsm/hwserver/_default.cfg

@@ -25,8 +25,6 @@ admins=""
 ## Advanced Server Start Settings
 # Rollback server state (remove after start command)
 loadsave=""
-# Use unstable 64 bit server executable (O/1)
-x64mode="0"
 
 ## Server Start Command | https://docs.linuxgsm.com/configuration/start-parameters#additional-parameters
 # Edit with care | http://hurtworld.wikia.com/wiki/Hosting_A_Server
@@ -119,11 +117,7 @@ engine="unity3d"
 ## Server Specific Directories
 systemdir="${serverfiles}"
 executabledir="${serverfiles}"
-if [ "${x64mode}" == "1" ]; then
-	executable="./Hurtworld.x86_64"
-else
-	executable="./Hurtworld.x86"
-fi
+executable=$([ "$(uname -m)" == "x86_64" ] && echo "./Hurtworld.x86_64" || echo "./Hurtworld.x86")
 
 ## Backup Directory
 backupdir="${rootdir}/backups"
@@ -143,4 +137,3 @@ postdetailslog="${lgsmlogdir}/${servicename}-postdetails.log"
 gamelogdate="${gamelogdir}/${servicename}-game-$(date '+%Y-%m-%d-%H:%M:%S').log"
 lgsmlogdate="${lgsmlogdir}/${servicename}-script-$(date '+%Y-%m-%d-%H:%M:%S').log"
 consolelogdate="${consolelogdir}/${servicename}-console-$(date '+%Y-%m-%d-%H:%M:%S').log"
-

+ 130 - 0
lgsm/config-default/config-lgsm/mhserver/_default.cfg

@@ -0,0 +1,130 @@
+##################################
+######## Default Settings ########
+##################################
+# DO NOT EDIT WILL BE OVERWRITTEN!
+# Copy settings from here and use them in either
+# common.cfg - applies settings to every instance
+# [instance].cfg - applies settings to a specific instance
+
+#### Server Settings ####
+
+## Server Start Settings | https://docs.linuxgsm.com/configuration/start-parameters
+ip="0.0.0.0"
+port="7777"
+beaconport="15000"
+queryport="27015"
+# Maps: FFA_Camp, FFA_Contraband, FFA_Grad, FFA_MountainPeak, FFA_Taiga, FFA_ThePit, FFA_Tourney, SKM_Camp, SKM_Contraband, SKM_Grad, SKM_MountainPeak, SKM_Taiga, SKM_ThePit, SKM_Tourney, TDM_Camp, TDM_Contraband, TDM_Grad, TDM_MountainPeak, TDM_Taiga, TDM_ThePit, TDM_Tourney
+defaultmap="FFA_ThePit"
+
+## Server Start Command | https://docs.linuxgsm.com/configuration/start-parameters#additional-parameters
+fn_parms(){
+parms="Mordhau ${defaultmap} -log -MultiHome=${ip} -Port=${port} -BeaconPort=${beaconport} -QueryPort=${queryport}"
+}
+
+#### LinuxGSM Settings ####
+
+## Notification Alerts
+# (on|off)
+
+# More info | https://docs.linuxgsm.com/alerts#more-info
+postalert="off"
+postdays="7"
+posttarget="https://hastebin.com"
+
+# Discord Alerts | https://docs.linuxgsm.com/alerts/discord
+discordalert="off"
+discordwebhook="webhook"
+
+# Email Alerts | https://docs.linuxgsm.com/alerts/email
+emailalert="off"
+email="email@example.com"
+emailfrom=""
+
+# IFTTT Alerts | https://docs.linuxgsm.com/alerts/ifttt
+iftttalert="off"
+ifttttoken="accesstoken"
+iftttevent="linuxgsm_alert"
+
+# Mailgun Email Alerts | https://docs.linuxgsm.com/alerts/mailgun
+mailgunalert="off"
+mailguntoken="accesstoken"
+mailgundomain="example.com"
+mailgunemailfrom="alert@example.com"
+mailgunemail="email@myemail.com"
+
+# Pushbullet Alerts | https://docs.linuxgsm.com/alerts/pushbullet
+pushbulletalert="off"
+pushbullettoken="accesstoken"
+channeltag=""
+
+# Pushover Alerts | https://docs.linuxgsm.com/alerts/pushover
+pushoveralert="off"
+pushovertoken="accesstoken"
+
+# Telegram Alerts | https://docs.linuxgsm.com/alerts/telegram
+# You can add a custom cURL string eg proxy (useful in Russia) or else in "curlcustomstring".
+# like a "--socks5 ipaddr:port" for socks5 proxy see more in "curl --help", if you not need
+# any custom string in curl - simple ignore this parameter.
+telegramalert="off"
+telegramtoken="accesstoken"
+telegramchatid=""
+curlcustomstring=""
+
+## Updating | https://docs.linuxgsm.com/commands/update
+updateonstart="off"
+
+## Backup | https://docs.linuxgsm.com/commands/backup
+maxbackups="4"
+maxbackupdays="30"
+stoponbackup="on"
+
+## Logging | https://docs.linuxgsm.com/features/logging
+consolelogging="on"
+logdays="7"
+
+#### LinuxGSM Advanced Settings ####
+
+# ANSI Colors
+ansi="on"
+
+## SteamCMD Settings
+# Server appid
+appid="629800"
+# Steam App Branch Select
+# Allows to opt into the various Steam app branches. Default branch is "".
+# Example: "-beta latest_experimental"
+branch=""
+
+## LinuxGSM Server Details
+# Do not edit
+gamename="MORDHAU"
+engine="unreal4"
+
+#### Directories ####
+# Edit with care
+
+## Server Specific Directories
+systemdir="${serverfiles}/Mordhau"
+executabledir="${systemdir}/Binaries/Linux"
+executable="./MordhauServer-Linux-Shipping"
+servercfgdir="${systemdir}/Saved/Config/LinuxServer"
+servercfg="Game.ini"
+servercfgdefault="Game.ini"
+servercfgfullpath="${servercfgdir}/${servercfg}"
+
+## Backup Directory
+backupdir="${lgsmdir}/backup"
+
+## Logging Directories
+logdir="${rootdir}/log"
+gamelogdir="${systemdir}/Saved/Logs"
+lgsmlogdir="${logdir}/script"
+consolelogdir="${logdir}/console"
+lgsmlog="${lgsmlogdir}/${servicename}-script.log"
+consolelog="${consolelogdir}/${servicename}-console.log"
+alertlog="${lgsmlogdir}/${servicename}-alert.log"
+postdetailslog="${lgsmlogdir}/${servicename}-postdetails.log"
+
+## Logs Naming
+lgsmlogdate="${lgsmlogdir}/${servicename}-script-$(date '+%Y-%m-%d-%H:%M:%S').log"
+consolelogdate="${consolelogdir}/${servicename}-console-$(date '+%Y-%m-%d-%H:%M:%S').log"

+ 1 - 1
lgsm/config-default/config-lgsm/q3server/_default.cfg

@@ -15,7 +15,7 @@ defaultmap="q3dm17"
 
 ## Server Start Command | https://docs.linuxgsm.com/configuration/start-parameters#additional-parameters
 fn_parms(){
-parms="+set sv_punkbuster 0 +set fs_basepath ${serverfiles} +set dedicated 1 +set com_hunkMegs 32 +set net_ip ${ip} +set net_port ${port} +exec ${servercfg} +map ${defaultmap}"
+parms="+set sv_punkbuster 0 +set fs_basepath ${serverfiles} +set dedicated 2 +set com_hunkMegs 32 +set net_ip ${ip} +set net_port ${port} +exec ${servercfg} +map ${defaultmap}"
 }
 
 #### LinuxGSM Settings ####

+ 2 - 5
lgsm/config-default/config-lgsm/qlserver/_default.cfg

@@ -8,12 +8,9 @@
 
 #### Server Settings ####
 
-## Server Start Settings | https://docs.linuxgsm.com/configuration/start-parameters
-arch="x64" # x64 or x86
-
 ## Server Start Command | https://docs.linuxgsm.com/configuration/start-parameters#additional-parameters
 # Edit with care | Install/Config Guide : https://steamcommunity.com/sharedfiles/filedetails/?id=542966946
-# Console Commands : http://www.regurge.at/ql/
+# Console Commands : http://www.regurge.at/ql
 fn_parms(){
 parms="+exec ${servercfg}"
 }
@@ -103,7 +100,7 @@ engine="idtech3_ql"
 ## Server Specific Directories
 systemdir="${serverfiles}"
 executabledir="${serverfiles}"
-executable=$([ "${arch}" == 'x64' ] && echo "./run_server_x64.sh" || echo "./run_server_x86.sh")
+executable=$([ "$(uname -m)" == "x86_64" ] && echo "./run_server_x64.sh" || echo "./run_server_x86.sh")
 servercfg="${servicename}.cfg"
 servercfgdefault="server.cfg"
 servercfgdir="${serverfiles}/baseq3"

+ 1 - 5
lgsm/config-default/config-lgsm/sdtdserver/_default.cfg

@@ -101,11 +101,7 @@ engine="unity3d"
 ## Server Specific Directories
 systemdir="${serverfiles}"
 executabledir="${serverfiles}"
-if [ "$(uname -m)" == "x86_64" ]; then
-	executable="./7DaysToDieServer.x86_64" 
-else
-	executable="./7DaysToDieServer.x86"
-fi	
+executable=$([ "$(uname -m)" == "x86_64" ] && echo "./7DaysToDieServer.x86_64" || echo "./7DaysToDieServer.x86")
 servercfgdefault="serverconfig.xml"
 servercfgdirdefault="${serverfiles}"
 servercfgfullpathdefault="${servercfgdirdefault}/${servercfgdefault}"

+ 1 - 0
lgsm/data/serverlist.csv

@@ -46,6 +46,7 @@ kf2,kf2server,Killing Floor 2
 l4d,l4dserver,Left 4 Dead
 l4d2,l4d2server,Left 4 Dead 2
 mc,mcserver,Minecraft
+mh,mhserver,MORDHAU
 mta,mtaserver,Multi Theft Auto
 mumble,mumbleserver,Mumble
 nd,ndserver,Nuclear Dawn

+ 3 - 0
lgsm/functions/check_system_requirements.sh

@@ -15,6 +15,9 @@ info_distro.sh
 if [ "${shortname}" == "ark" ]; then
 	ramrequirementmb="4000"
 	ramrequirementgb="4"
+elif [ "${shortname}" == "mh" ]; then
+	ramrequirementmb="4000"
+	ramrequirementgb="4"
 elif [ "${shortname}" == "arma3" ]; then
 	ramrequirementmb="1000"
 	ramrequirementgb="1"

+ 39 - 11
lgsm/functions/command_dev_query_raw.sh

@@ -7,8 +7,10 @@
 local commandname="QUERY-RAW"
 local commandaction="Query Raw"
 local function_selfname="$(basename "$(readlink -f "${BASH_SOURCE[0]}")")"
-
-echo "================================="
+echo ""
+echo "Query Port"
+echo "=================================================================="
+echo ""
 echo "Gamedig Raw Output"
 echo "================================="
 echo""
@@ -33,7 +35,6 @@ echo "${gamedigcmd}"
 echo""
 echo "${gamedigraw}" | jq
 echo""
-echo "================================="
 echo "gsquery Raw Output"
 echo "================================="
 echo""
@@ -44,29 +45,56 @@ fi
 "${functionsdir}"/query_gsquery.py -a "${ip}" -p "${queryport}" -e "${engine}"
 
 echo""
-echo "================================="
-echo "tcp Raw Output"
+echo "TCP Raw Output"
 echo "================================="
 echo""
 echo "bash -c 'exec 3<> /dev/tcp/'${ip}'/'${queryport}''"
 bash -c 'exec 3<> /dev/tcp/'${ip}'/'${queryport}''
 querystatus="$?"
 if [ "${querystatus}" == "0" ]; then
-	echo "tcp query PASS"
+	echo "TCP query PASS"
 else
-	echo "tcp query FAIL"
+	echo "TCP query FAIL"
 fi
 
 echo""
-echo "================================="
-echo "udp Raw Output"
+echo "UDP Raw Output"
 echo "================================="
 echo""
 echo "bash -c 'exec 3<> /dev/udp/'${ip}'/'${queryport}''"
 bash -c 'exec 3<> /dev/udp/'${ip}'/'${queryport}''
 querystatus="$?"
 if [ "${querystatus}" == "0" ]; then
-	echo "udp query PASS"
+	echo "UPD query PASS"
+else
+	echo "UPD query FAIL"
+fi
+echo ""
+echo "Game Port"
+echo "=================================================================="
+echo ""
+echo""
+echo "TCP Raw Output"
+echo "================================="
+echo""
+echo "bash -c 'exec 3<> /dev/tcp/'${ip}'/'${port}''"
+bash -c 'exec 3<> /dev/tcp/'${ip}'/'${port}''
+querystatus="$?"
+if [ "${querystatus}" == "0" ]; then
+	echo "TCP query PASS"
+else
+	echo "TCP query FAIL"
+fi
+
+echo""
+echo "UDP Raw Output"
+echo "================================="
+echo""
+echo "bash -c 'exec 3<> /dev/udp/'${ip}'/'${port}''"
+bash -c 'exec 3<> /dev/udp/'${ip}'/'${port}''
+querystatus="$?"
+if [ "${querystatus}" == "0" ]; then
+	echo "UDP query PASS"
 else
-	echo "udp query FAIL"
+	echo "UDP query FAIL"
 fi

+ 22 - 0
lgsm/functions/info_config.sh

@@ -1146,6 +1146,26 @@ fn_info_config_stationeers(){
 	fi
 }
 
+fn_info_config_mordhau(){
+	if [ ! -f "${servercfgfullpath}" ]; then
+		servername="${unavailable}"
+		serverpassword="${unavailable}"
+		rconpassword="${unavailable}"
+		maxplayers="${unavailable}"
+	else
+		servername=$(grep "ServerName" "${servercfgfullpath}" | awk -F '=' '{print $2}')
+		serverpassword=$(grep "ServerPassword" "${servercfgfullpath}" | awk -F '=' '{print $2}')
+		rconpassword=$(grep "AdminPassword" "${servercfgfullpath}" | awk -F '=' '{print $2}')
+		maxplayers=$(grep "MaxSlots" "${servercfgfullpath}" | awk -F '=' '{print $2}')
+
+		# Not set
+		servername=${servername:-"NOT SET"}
+		serverpassword=${serverpassword:-"NOT SET"}
+		rconpassword=${rconpassword:-"NOT SET"}
+		maxplayers=${maxplayers:-"0"}
+	fi
+}
+
 # ARK: Survival Evolved
 if [ "${shortname}" == "ark" ]; then
 	fn_info_config_ark
@@ -1276,4 +1296,6 @@ elif [ "${shortname}" == "squad" ]; then
 # Stationeers
 elif [ "${shortname}" == "st" ]; then
 	fn_info_config_stationeers
+elif [ "${shortname}" == "mh" ]; then
+	fn_info_config_mordhau
 fi

+ 3 - 0
lgsm/functions/info_glibc.sh

@@ -147,6 +147,9 @@ elif [ "${gamename}" == "NS2: Combat" ]; then
 elif [ "${gamename}" == "TeamSpeak 3" ]; then
 	glibcrequired="NOT REQUIRED"
 	glibcfix="no"
+elif [ "${gamename}" == "MORDHAU" ]; then
+	glibcrequired="2.17"
+	glibcfix="no"
 elif [ "${gamename}" == "Mumble" ]; then
 	glibcrequired="NOT REQUIRED"
 	glibcfix="no"

+ 13 - 0
lgsm/functions/info_messages.sh

@@ -1179,6 +1179,17 @@ fn_info_message_mta(){
 	} | column -s $'\t' -t
 }
 
+fn_info_message_mordhau(){
+	echo -e "netstat -atunp | grep Mord"
+	echo -e ""
+	{
+		echo -e "DESCRIPTION\tDIRECTION\tPORT\tPROTOCOL"
+		echo -e "> Game\tINBOUND\t${port}\tudp"
+		echo -e "> BeaconPort\tINBOUND\t${beaconport}\tudp"
+		echo -e "> Query\tINBOUND\t${queryport}\tudp"
+	} | column -s $'\t' -t
+}
+
 fn_info_message_select_engine(){
 	# Display details depending on game or engine.
 	if [ "${gamename}" == "7 Days To Die" ]; then
@@ -1241,6 +1252,8 @@ fn_info_message_select_engine(){
 		fn_info_message_towerunite
 	elif [ "${shortname}" == "unt" ]; then
 		fn_info_message_unturned
+	elif [ "${shortname}" == "mh" ]; then
+		fn_info_message_mordhau
 	elif [ "${gamename}" == "Multi Theft Auto" ]; then
 		fn_info_message_mta
 	elif [ "${gamename}" == "Mumble" ]; then

+ 11 - 3
lgsm/functions/info_parms.sh

@@ -141,11 +141,17 @@ fn_info_parms_stickybots(){
 	maxplayers=${maxplayers:-"0"}
 }
 
-fn_info_config_towerunite(){
+fn_info_parms_towerunite(){
 	port=${port:-"0"}
 	queryport=${queryport:-"0"}
 }
 
+fn_info_parms_mordhau(){
+	port=${port:-"0"}
+	queryport=${queryport:-"0"}
+	beaconport=${beaconport:-"0"}
+}
+
 fn_info_parms_unreal(){
 	defaultmap=${defaultmap:-"NOT SET"}
 	queryport=$((port + 1))
@@ -213,14 +219,16 @@ elif [ "${shortname}" == "sbots" ]; then
 	fn_info_parms_stickybots
 # Serious Sam
 elif [ "${shortname}" == "ss3" ]; then
-	fn_info_config_seriousengine35
+	fn_info_parms_seriousengine35
 elif [ "${engine}" == "source" ]||[ "${engine}" == "goldsource" ]; then
 	fn_info_parms_source
 # Spark
 elif [ "${engine}" == "spark" ]; then
 	fn_info_parms_spark
 elif [ "${shortname}" == "tu" ]; then
-	fn_info_config_towerunite
+	fn_info_parms_towerunite
+elif [ "${shortname}" == "mh" ]; then
+	fn_info_parms_mordhau
 # Unreal/Unreal 2 engine
 elif [ "${engine}" == "unreal" ]||[ "${engine}" == "unreal2" ]; then
 	fn_info_parms_unreal

+ 7 - 0
lgsm/functions/install_config.sh

@@ -427,6 +427,13 @@ elif [ "${gamename}" == "Minecraft" ]; then
 	fn_fetch_default_config
 	fn_default_config_remote
 	fn_set_config_vars
+elif [ "${gamename}" == "MORDHAU" ]; then
+	gamedirname="Mordhau"
+	fn_check_cfgdir
+	array_configs+=( Game.ini )
+	fn_fetch_default_config
+	fn_default_config_remote
+	fn_set_config_vars
 elif [ "${gamename}" == "Natural Selection" ]; then
 	gamedirname="NaturalSelection"
 	array_configs+=( server.cfg )

+ 2 - 2
lgsm/functions/install_server_files.sh

@@ -34,9 +34,9 @@ fn_install_server_files(){
 	elif [ "${shortname}" == "q3" ]; then
 		remote_fileurl="https://files.linuxgsm.com/Quake3/quake3-1.32c-x86-full-linux.tar.bz2"; local_filedir="${tmpdir}"; local_filename="quake3-1.32c-x86-full-linux.tar.bz2"; chmodx="nochmodx" run="norun"; force="noforce"; md5="fd7258d827474f67663dda297bff4306"
 	elif [ "${shortname}" == "qw" ]; then
-		remote_fileurl="https://files.linuxgsm.com/QuakeWorld/nquake.server.linux.083116.full.tar.bz2"; local_filedir="${tmpdir}"; local_filename="nquake.server.linux.083116.full.tar.bz2"; chmodx="nochmodx" run="norun"; force="noforce"; md5="75a409cf08d808f075e4dacdc7b21b78"
+		remote_fileurl="https://files.linuxgsm.com/QuakeWorld/nquake.server.linux.190506.full.tar.bz2"; local_filedir="${tmpdir}"; local_filename="nquake.server.linux.190506.full.tar.bz2"; chmodx="nochmodx" run="norun"; force="noforce"; md5="74405ec030463c5e1175e776ab572d32"
 	elif [ "${shortname}" == "rtcw" ]; then
-		remote_fileurl="https://files.linuxgsm.com/ReturnToCastleWolfenstein/iortcw-1.51b-x86_64-server-linux-20190208.tar.bz2"; local_filedir="${tmpdir}"; local_filename="iortcw-1.51b-x86_64-server-linux-20190208.tar.bz2"; chmodx="nochmodx" run="norun"; force="noforce"; md5="7e555481a3b98e168dfb5e6ddc2fb879"
+		remote_fileurl="https://files.linuxgsm.com/ReturnToCastleWolfenstein/iortcw-1.51c-x86_64-server-linux-20190507.tar.bz2"; local_filedir="${tmpdir}"; local_filename="iortcw-1.51c-x86_64-server-linux-20190507.tar.bz2"; chmodx="nochmodx" run="norun"; force="noforce"; md5="6a3be9700372b228d1187422464e4212"
 	elif [ "${shortname}" == "ut2k4" ]; then
 		remote_fileurl="https://files.linuxgsm.com/UnrealTournament2004/ut2004-server-3369-2-ultimate-linux.tar.bz2"; local_filedir="${tmpdir}"; local_filename="ut2004-server-3369-2-ultimate-linux.tar.bz2"; chmodx="nochmodx" run="norun"; force="noforce"; md5="67c5e2cd9c2a4b04f163962ee41eff54"
 	elif [ "${shortname}" == "ut99" ]; then

+ 1 - 1
lgsm/functions/update_minecraft.sh

@@ -81,7 +81,7 @@ fn_update_minecraft_localbuild(){
 				loopignore=1
 				fn_script_log_info "Waiting for local build to generate"
 			fi
-			localbuild=$(cat "${serverfiles}/logs/latest.log" 2> /dev/null | grep version | grep -Eo '((\.)?[0-9]{1,3}){1,3}\.[0-9]{1,3}' | grep -Eo "TeamSpeak 3 Server ((\.)?[0-9]{1,3}){1,3}\.[0-9]{1,3}" | grep -Eo "((\.)?[0-9]{1,3}){1,3}\.[0-9]{1,3}")
+			localbuild=$(cat "${serverfiles}/logs/latest.log" 2> /dev/null | grep version | grep -Eo '((\.)?[0-9]{1,3}){1,3}\.[0-9]{1,3}')
 			if [ "${localbuild}" ]||[ "${seconds}" == "120" ]; then
 				break
 			fi

+ 1 - 1
linuxgsm.sh

@@ -20,7 +20,7 @@ if [ -f ".dev-debug" ]; then
 	set -x
 fi
 
-version="190503"
+version="v19.6.0"
 shortname="core"
 gameservername="core"
 rootdir="$(dirname "$(readlink -f "${BASH_SOURCE[0]}")")"