+ added "testing" option for travis

This commit is contained in:
Lucas Briese 2018-09-19 23:22:05 +02:00
parent fa66695b59
commit e503b0c954
2 changed files with 14 additions and 4 deletions

View File

@ -4,5 +4,5 @@ services:
script:
- docker build -t "jusito/docker-ttt:develop" .
- docker volume create TTT
- docker run -ti --name "TTT" -p 27015:27015/tcp -p 27015:27015/udp -v "TTT:/home/steam/server:rw" \
"jusito/docker-ttt:develop" -port 27015 -maxplayers 16 +map ttt_rooftops_2016_v1 -usercon +rcon_password "testing" -debug
- docker run -d -P -e INSTALL_CSS=true -e WORKSHOP_COLLECTION_ID=899062542 --name "TTT" -p 27015:27015/tcp -p 27015:27015/udp -v "TTT:/home/steam/server:rw" \
"jusito/docker-ttt:develop" "testing"

View File

@ -2,6 +2,11 @@
echo "starting entrypoint.sh"
set -e
DEBUG_MODE=false
if [ "$1" = "testing" ]; then
DEBUG_MODE=true
fi
echo "installing / updating steamcmd"
cd "$STEAM_PATH"
wget -q -O - "https://steamcdn-a.akamaihd.net/client/installer/steamcmd_linux.tar.gz" | tar -zxvf -
@ -45,5 +50,10 @@ fi
# todo catch => send killserver / quit
cd "$STEAM_PATH/server/"
trap 'pkill -15 srcds_run' SIGTERM
if [ "$DEBUG_MODE" != "true" ]; then
./srcds_run -console -game garrysmod +gamemode terrortown "$@" &
wait "$!"
else
echo "debug ended"
fi