Browse Source

feat(veinserver): add VEIN server (#5219)

Adds the native Linux dedicated server for VEIN (veinserver), Steam appid 2131400 via anonymous SteamCMD. Monitor uses the TCP query mode against the game's HTTP status endpoint (HTTPPort, default 8080) on 127.0.0.1, since the Steam query port does not answer A2S. A default Game.ini is installed from Game-Server-Configs.

Fixes #4585
Daniel Gibbs 1 ngày trước cách đây
mục cha
commit
4f1525fcd0

+ 217 - 0
lgsm/config-default/config-lgsm/veinserver/_default.cfg

@@ -0,0 +1,217 @@
+##################################
+######## Default Settings ########
+##################################
+# DO NOT EDIT, ANY CHANGES 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.
+
+#### Game Server Settings ####
+
+## Predefined Parameters | https://docs.linuxgsm.com/configuration/start-parameters
+port="7777"
+queryport="8080"
+steamport="27015"
+
+## Server Parameters | https://docs.linuxgsm.com/configuration/start-parameters#additional-parameters
+startparameters="Vein -Port=${port} -QueryPort=${steamport} -log '-ini:Game:[/Script/Vein.VeinGameSession]:HTTPPort=${queryport}'"
+
+## Extra Parameters | https://docs.linuxgsm.com/configuration/start-parameters#extra-parameters
+# Added to the end of startparameters.
+extraparams=""
+
+#### LinuxGSM Settings ####
+
+## LinuxGSM Stats
+# Send useful stats to LinuxGSM developers.
+# https://docs.linuxgsm.com/configuration/linuxgsm-stats
+# (on|off)
+stats="off"
+
+## Notification Alerts
+# (on|off)
+
+# Display IP | https://docs.linuxgsm.com/alerts#display-ip
+displayip=""
+
+# More info | https://docs.linuxgsm.com/alerts#more-info
+postalert="off"
+
+# Alert on Start/Stop/Restart
+statusalert="off"
+
+# Minutes to wait between repeated monitor alerts, 0 sends every alert
+alertcooldown="0"
+
+# 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=""
+
+# Gotify Alerts | https://docs.linuxgsm.com/alerts/gotify
+gotifyalert="off"
+gotifytoken="token"
+gotifywebhook="webhook"
+
+# IFTTT Alerts | https://docs.linuxgsm.com/alerts/ifttt
+iftttalert="off"
+ifttttoken="accesstoken"
+iftttevent="linuxgsm_alert"
+
+# ntfy Alerts | https://docs.linuxgsm.com/alerts/ntfy
+ntfyalert="off"
+ntfytopic="LinuxGSM"
+ntfyserver="https://ntfy.sh"
+ntfytoken=""
+ntfyusername=""
+ntfypassword=""
+ntfypriority=""
+ntfytags=""
+
+# Matrix Alerts | https://docs.linuxgsm.com/alerts/matrix
+matrixalert="off"
+matrixhomeserver="matrix.org"
+matrixtoken="accesstoken"
+matrixroom=""
+
+# 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"
+pushoveruserkey="userkey"
+
+# Rocket.Chat Alerts | https://docs.linuxgsm.com/alerts/rocket.chat
+rocketchatalert="off"
+rocketchatwebhook="webhook"
+
+# Slack Alerts | https://docs.linuxgsm.com/alerts/slack
+slackalert="off"
+slackwebhook="webhook"
+
+# Telegram Alerts | https://docs.linuxgsm.com/alerts/telegram
+# You can add a custom cURL string eg proxy (useful in Russia) in "curlcustomstring".
+# For example "--socks5 ipaddr:port" for socks5 proxy see more in "curl --help all".
+telegramapi="api.telegram.org"
+telegramalert="off"
+telegramtoken="accesstoken"
+telegramchatid=""
+telegramthreadid=""
+telegramsilentnotification="false"
+curlcustomstring=""
+
+## Stop | https://docs.linuxgsm.com/commands/start-stop-restart
+stoponlyifnoplayers="off"
+stoponlyifnoplayersallcommands="on"
+
+## Player Warnings | https://docs.linuxgsm.com/features/player-warnings
+# Minutes to warn players in-game before a stop, restart or update. 0 to disable.
+# e.g. 15 warns at 15, 10, 5, 3 and 1 minutes.
+warnplayerstimer="0"
+
+## 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"
+
+## Monitor | https://docs.linuxgsm.com/commands/monitor
+# Query delay time
+querydelay="5"
+
+## ANSI Colors | https://docs.linuxgsm.com/features/ansi-colors
+ansi="on"
+
+#### Advanced Settings ####
+
+## Message Display Time | https://docs.linuxgsm.com/features/message-display-time
+sleeptime="0.5"
+
+## SteamCMD Settings | https://docs.linuxgsm.com/steamcmd
+# Server appid
+appid="2131400"
+steamcmdforcewindows="no"
+# SteamCMD Branch | https://docs.linuxgsm.com/steamcmd/branch
+branch=""
+betapassword=""
+# Master Server | https://docs.linuxgsm.com/steamcmd/steam-master-server
+steammaster="false"
+
+## Stop Mode | https://docs.linuxgsm.com/features/stop-mode
+# 1: tmux kill
+# 2: CTRL+c
+# 3: quit
+# 4: quit 120s
+# 5: stop
+# 6: q
+# 7: exit
+# 8: 7 Days to Die
+# 9: GoldSrc
+# 10: Avorion
+# 11: end
+stopmode="2"
+
+## Query mode
+# 1: session only
+# 2: gamedig (gsquery fallback)
+# 3: gamedig
+# 4: gsquery
+# 5: tcp
+querymode="5"
+querytype=""
+
+## Console type
+consoleverbose="yes"
+consoleinteract="no"
+
+## Game Server Details
+# Do not edit
+gamename="VEIN"
+engine="unreal5"
+glibc="2.28"
+
+#### Directories ####
+# Edit with care
+
+## Game Server Directories
+systemdir="${serverfiles}/Vein"
+executabledir="${systemdir}/Binaries/Linux"
+executable="./VeinServer-Linux-Test"
+servercfgdir="${systemdir}/Saved/Config/LinuxServer"
+servercfg="Game.ini"
+servercfgdefault="Game.ini"
+servercfgfullpath="${servercfgdir}/${servercfg}"
+
+## Backup Directory
+backupdir="${lgsmdir}/backup"
+
+## Logging Directories
+[ -n "${LGSM_LOGDIR}" ] && logdir="${LGSM_LOGDIR}" || logdir="${rootdir}/log"
+gamelogdir="${systemdir}/Saved/Logs"
+lgsmlogdir="${logdir}/script"
+consolelogdir="${logdir}/console"
+lgsmlog="${lgsmlogdir}/${selfname}-script.log"
+consolelog="${consolelogdir}/${selfname}-console.log"
+alertlog="${lgsmlogdir}/${selfname}-alert.log"
+postdetailslog="${lgsmlogdir}/${selfname}-postdetails.log"
+
+## Logs Naming
+lgsmlogdate="${lgsmlogdir}/${selfname}-script-$(date '+%Y-%m-%d-%H:%M:%S').log"
+consolelogdate="${consolelogdir}/${selfname}-console-$(date '+%Y-%m-%d-%H:%M:%S').log"
+
+## Log Parameters
+logtimestamp="off"
+logtimestampformat="%Y-%m-%d %H:%M:%S"

+ 1 - 0
lgsm/data/almalinux-8.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,glibc-devel,libatomic,pulseaudio-libs-devel
 vints,dotnet-runtime-8.0
 vpmc,java-21-openjdk

+ 1 - 0
lgsm/data/almalinux-9.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,glibc-devel,libatomic,pulseaudio-libs-devel
 vints,dotnet-runtime-8.0
 vpmc,java-21-openjdk

+ 1 - 0
lgsm/data/centos-7.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,glibc-devel,libatomic,pulseaudio-libs-devel
 vints,dotnet-runtime-8.0
 vpmc,java-11-openjdk

+ 1 - 0
lgsm/data/centos-8.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,glibc-devel,libatomic,pulseaudio-libs-devel
 vints,dotnet-runtime-8.0
 vpmc,java-17-openjdk

+ 1 - 0
lgsm/data/centos-9.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,glibc-devel,libatomic,pulseaudio-libs-devel
 vints,dotnet-runtime-8.0
 vpmc,java-17-openjdk

+ 1 - 0
lgsm/data/debian-10.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,libc6-dev,libatomic1,libpulse-dev
 vints,dotnet-runtime-8.0
 vpmc,openjdk-11-jre

+ 1 - 0
lgsm/data/debian-11.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,libc6-dev,libatomic1,libpulse-dev
 vints,dotnet-runtime-8.0
 vpmc,openjdk-11-jre

+ 1 - 0
lgsm/data/debian-12.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,libc6-dev,libatomic1,libpulse-dev
 vints,dotnet-runtime-10.0
 vpmc,openjdk-17-jre

+ 1 - 0
lgsm/data/debian-13.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,libc6-dev,libatomic1,libpulse-dev
 vints,dotnet-runtime-10.0
 vpmc,openjdk-25-jre

+ 1 - 0
lgsm/data/debian-9.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,libc6-dev,libatomic1,libpulse-dev
 vints,dotnet-runtime-8.0
 vpmc,openjdk-8-jre

BIN
lgsm/data/gameicons/vein-icon.png


+ 1 - 0
lgsm/data/rhel-7.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,glibc-devel,libatomic,pulseaudio-libs-devel
 vints,dotnet-runtime-8.0
 vpmc,java-11-openjdk

+ 1 - 0
lgsm/data/rhel-8.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,glibc-devel,libatomic,pulseaudio-libs-devel
 vints,dotnet-runtime-8.0
 vpmc,java-21-openjdk

+ 1 - 0
lgsm/data/rhel-9.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,glibc-devel,libatomic,pulseaudio-libs-devel
 vints,dotnet-runtime-8.0
 vpmc,java-21-openjdk

+ 1 - 0
lgsm/data/rocky-8.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,glibc-devel,libatomic,pulseaudio-libs-devel
 vints,dotnet-runtime-8.0
 vpmc,java-21-openjdk

+ 1 - 0
lgsm/data/rocky-9.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,glibc-devel,libatomic,pulseaudio-libs-devel
 vints,dotnet-runtime-8.0
 vpmc,java-21-openjdk

+ 1 - 0
lgsm/data/serverlist.csv

@@ -138,6 +138,7 @@ ut,utserver,Unreal Tournament,ubuntu-26.04
 ut2k4,ut2k4server,Unreal Tournament 2004,ubuntu-26.04
 ut3,ut3server,Unreal Tournament 3,ubuntu-26.04
 ut99,ut99server,Unreal Tournament 99,ubuntu-26.04
+vein,veinserver,VEIN,ubuntu-26.04
 vh,vhserver,Valheim,ubuntu-26.04
 vints,vintsserver,Vintage Story,ubuntu-26.04
 vpmc,vpmcserver,Velocity Proxy MC,ubuntu-26.04

+ 1 - 0
lgsm/data/ubuntu-16.04.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,libc6-dev,libatomic1,libpulse-dev
 vints,dotnet-runtime-8.0
 vpmc,openjdk-8-jre

+ 1 - 0
lgsm/data/ubuntu-18.04.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,libc6-dev,libatomic1,libpulse-dev
 vints,dotnet-runtime-8.0
 vpmc,openjdk-11-jre

+ 1 - 0
lgsm/data/ubuntu-20.04.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,libc6-dev,libatomic1,libpulse-dev
 vints,dotnet-runtime-8.0
 vpmc,openjdk-11-jre

+ 1 - 0
lgsm/data/ubuntu-22.04.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,libc6-dev,libatomic1,libpulse-dev
 vints,dotnet-runtime-8.0
 vpmc,openjdk-21-jre

+ 1 - 0
lgsm/data/ubuntu-23.04.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,libc6-dev,libatomic1,libpulse-dev
 vints,dotnet-runtime-8.0
 vpmc,openjdk-21-jre

+ 1 - 0
lgsm/data/ubuntu-23.10.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,libc6-dev,libatomic1,libpulse-dev
 vints,dotnet-runtime-8.0
 vpmc,openjdk-21-jre

+ 1 - 0
lgsm/data/ubuntu-24.04.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,libc6-dev,libatomic1,libpulse-dev
 vints,dotnet-runtime-10.0
 vpmc,openjdk-25-jre

+ 1 - 0
lgsm/data/ubuntu-26.04.csv

@@ -139,6 +139,7 @@ ut
 ut2k4
 ut3
 ut99
+vein
 vh,libc6-dev,libatomic1,libpulse-dev
 vints,dotnet-runtime-10.0
 vpmc,openjdk-25-jre

+ 2 - 0
lgsm/modules/check_system_requirements.sh

@@ -71,6 +71,8 @@ elif [ "${shortname}" == "stn" ]; then
 	ramrequirementgb="3"
 elif [ "${shortname}" == "tu" ]; then
 	ramrequirementgb="2"
+elif [ "${shortname}" == "vein" ]; then
+	ramrequirementgb="4"
 elif [ "${shortname}" == "vh" ]; then
 	ramrequirementgb="2"
 else

+ 10 - 0
lgsm/modules/info_game.sh

@@ -2297,6 +2297,14 @@ fn_info_game_unt() {
 	steamport="$((port + 1))"
 }
 
+# Config Type: Parameters
+fn_info_game_vein() {
+	queryips=("127.0.0.1" "${queryips[@]}")
+	port="${port:-"0"}"
+	queryport="${queryport:-"0"}"
+	steamport="${steamport:-"0"}"
+}
+
 # Config Type: Parameters
 fn_info_game_vh() {
 	port="${port:-"0"}"
@@ -2670,6 +2678,8 @@ elif [ "${shortname}" == "ut3" ]; then
 	fn_info_game_ut3
 elif [ "${shortname}" == "ut99" ]; then
 	fn_info_game_ut99
+elif [ "${shortname}" == "vein" ]; then
+	fn_info_game_vein
 elif [ "${shortname}" == "vh" ]; then
 	fn_info_game_vh
 elif [ "${shortname}" == "bmp" ]; then

+ 14 - 1
lgsm/modules/info_messages.sh

@@ -771,7 +771,7 @@ fn_info_messages_ports_edit() {
 		fi
 	done
 	# engines/games that require editing the start parameters.
-	local ports_edit_array=("av" "ce" "ck" "col" "cs2" "fctr" "goldsrc" "hcu" "hw" "bmp" "mdt" "hyt" "luanti" "iw3.0" "ioquake3" "openra" "pw" "qfusion" "rsdw" "rust" "scpsl" "sf" "sol" "spark" "source" "unreal4" "arma3" "dayz" "unt" "vh")
+	local ports_edit_array=("av" "ce" "ck" "col" "cs2" "fctr" "goldsrc" "hcu" "hw" "bmp" "mdt" "hyt" "luanti" "iw3.0" "ioquake3" "openra" "pw" "qfusion" "rsdw" "rust" "scpsl" "sf" "sol" "spark" "source" "unreal4" "arma3" "dayz" "unt" "vein" "vh")
 	for port_edit in "${ports_edit_array[@]}"; do
 		if [ "${engine}" == "${port_edit}" ] || [ "${gamename}" == "${port_edit}" ] || [ "${shortname}" == "${port_edit}" ]; then
 			startparameterslocation="${configdirserver}"
@@ -807,6 +807,8 @@ fn_info_messages_ports() {
 		portcommand="ss -tuplwn | grep java"
 	elif [ "${shortname}" == "terraria" ]; then
 		portcommand="ss -tuplwn | grep Main"
+	elif [ "${shortname}" == "vein" ]; then
+		portcommand="ss -tuplwn | grep VeinServer-Linu"
 	elif [ "${shortname}" == "sm" ]; then
 		portcommand="ss -tuplwn | grep WSServer-Linux"
 	elif [ "${querytype}" == "protocol-valve-won" ]; then
@@ -1853,6 +1855,15 @@ fn_info_messages_ut3() {
 	} | column -s $'\t' -t
 }
 
+fn_info_messages_vein() {
+	{
+		fn_port "header"
+		fn_port "Game" port udp
+		fn_port "Query" queryport tcp
+		fn_port "Steam" steamport udp
+	} | column -s $'\t' -t
+}
+
 fn_info_messages_vh() {
 	{
 		fn_port "header"
@@ -2105,6 +2116,8 @@ fn_info_messages_select_engine() {
 		fn_info_messages_tw
 	elif [ "${shortname}" == "unt" ]; then
 		fn_info_messages_unt
+	elif [ "${shortname}" == "vein" ]; then
+		fn_info_messages_vein
 	elif [ "${shortname}" == "vh" ]; then
 		fn_info_messages_vh
 	elif [ "${shortname}" == "bmp" ]; then

+ 4 - 0
lgsm/modules/install_config.sh

@@ -280,6 +280,10 @@ elif [ "${shortname}" == "luanti" ]; then
 		} >> "${servercfgfullpath}"
 	fi
 	fn_list_config_locations
+elif [ "${shortname}" == "vein" ]; then
+	array_configs+=(Game.ini)
+	fn_default_config_remote
+	fn_list_config_locations
 elif [ "${shortname}" == "orar" ]; then
 	fn_check_cfgdir
 	fn_list_config_locations