Hopefully fixed up the tmux session for the TS server.

This commit is contained in:
Storm Dragon
2026-04-17 15:23:08 -04:00
parent 5e64317744
commit 73117bfa7d

View File

@@ -9,6 +9,7 @@ topspeedServiceScript="${topspeedInstallDir}/topspeed-service.sh"
topspeedStopScript="${topspeedInstallDir}/topspeed-stop.sh"
topspeedBinaryPath="${topspeedRuntimeDir}/TopSpeed.Server"
topspeedSessionName="topspeed"
topspeedTmuxShell="/bin/bash"
topspeedRepoApi="https://api.github.com/repos/diamondStar35/top_speed/releases"
topspeedAssetPattern='^TopSpeed\.Server-linux-arm64-Release-v-.*\.zip$'
topspeedServerPort="28630"
@@ -170,6 +171,7 @@ cat > "$tempServiceScript" <<EOF
sessionName="${topspeedSessionName}"
runtimeDir="${topspeedRuntimeDir}"
binaryPath="${topspeedBinaryPath}"
tmuxShell="${topspeedTmuxShell}"
cd "\$runtimeDir" || exit 1
if tmux has-session -t "\$sessionName" &> /dev/null; then
@@ -180,7 +182,9 @@ if [[ ! -x "\$binaryPath" ]]; then
exit 1
fi
tmux new-session -d -s "\$sessionName" "./TopSpeed.Server" || exit 1
tmux start-server
tmux set-option -g default-shell "\$tmuxShell"
tmux new-session -d -s "\$sessionName" 'exec ./TopSpeed.Server' || exit 1
while tmux has-session -t "\$sessionName" &> /dev/null; do
sleep 5