From cc3d4ddce46be46ec8cc34fef67d5ff8ee9800cd Mon Sep 17 00:00:00 2001 From: John Edwards Date: Fri, 27 Oct 2023 09:26:43 +0100 Subject: [PATCH] Added support for TV client password --- README.md | 1 + bullseye/Dockerfile | 1 + bullseye/etc/entry.sh | 1 + bullseye/etc/server.cfg | 1 + examples/docker-compose.yml | 1 + 5 files changed, 5 insertions(+) diff --git a/README.md b/README.md index 4a1354b..09cdab5 100644 --- a/README.md +++ b/README.md @@ -98,6 +98,7 @@ CS2_BOT_QUOTA_MODE="" (fill, competitive) TV_ENABLE=1 (0 - disable, 1 - enable) TV_PORT=27020 (SourceTV/CSTV port to bind to) TV_AUTORECORD=0 (Automatically record all games as CSTV demos: 0=off, 1=on) +TV_PW="changeme" (CSTV password for clients) TV_RELAY_PW="changeme" (CSTV password for relay proxies) ``` diff --git a/bullseye/Dockerfile b/bullseye/Dockerfile index 058e90a..7ea93b3 100644 --- a/bullseye/Dockerfile +++ b/bullseye/Dockerfile @@ -55,6 +55,7 @@ ENV CS2_SERVERNAME="cs2 private server" \ TV_AUTORECORD=0 \ TV_ENABLE=1 \ TV_PORT=27020 \ + TV_PW="changeme" \ TV_RELAY_PW="changeme" \ CS2_ADDITIONAL_ARGS="" diff --git a/bullseye/etc/entry.sh b/bullseye/etc/entry.sh index 688fae6..9c2a737 100644 --- a/bullseye/etc/entry.sh +++ b/bullseye/etc/entry.sh @@ -21,6 +21,7 @@ sed -i -e "s/{{SERVER_HOSTNAME}}/${CS2_SERVERNAME}/g" \ -e "s/{{TV_ENABLE}}/${TV_ENABLE}/g" \ -e "s/{{TV_PORT}}/${TV_PORT}/g" \ -e "s/{{TV_AUTORECORD}}/${TV_AUTORECORD}/g" \ + -e "s/{{TV_PW}}/${TV_PW}/g" \ -e "s/{{TV_RELAY_PW}}/${TV_RELAY_PW}/g" \ "${STEAMAPPDIR}"/game/csgo/cfg/server.cfg diff --git a/bullseye/etc/server.cfg b/bullseye/etc/server.cfg index 0c85c8e..cf1a849 100644 --- a/bullseye/etc/server.cfg +++ b/bullseye/etc/server.cfg @@ -28,6 +28,7 @@ tv_maxrate 20000 // Max CSTV spectator bandwidth rate allowed tv_name "{{SERVER_HOSTNAME}} CSTV" // CSTV host name tv_overridemaster 0 // Overrides the CSTV master root address. tv_port {{TV_PORT}} // Host SourceTV port +tv_password "{{TV_PW}}" // CSTV password for clients tv_relaypassword "{{TV_RELAY_PW}}" // CSTV password for relay proxies tv_relayvoice 1 // Relay voice data: 0=off, 1=on tv_snapshotrate 24 // Snapshots broadcasted per second diff --git a/examples/docker-compose.yml b/examples/docker-compose.yml index f0eab49..f536aee 100644 --- a/examples/docker-compose.yml +++ b/examples/docker-compose.yml @@ -32,6 +32,7 @@ services: - TV_AUTORECORD=0 # Automatically records all games as CSTV demos: 0=off, 1=on. - TV_ENABLE=1 # Activates CSTV on server: 0=off, 1=on. - TV_PORT=27020 # Host SourceTV port + - TV_PW=changeme # CSTV password for clients - TV_RELAY_PW=changeme # CSTV password for relay proxies volumes: - cs2:/home/steam/cs2-dedicated/ # (Change /mnt/cs2 according to your volume location)