From 2252753d072bfdbc83131022268fcd4384ed24e5 Mon Sep 17 00:00:00 2001 From: Lars Olzem Date: Sat, 6 Jun 2020 18:42:20 +0200 Subject: [PATCH] add WorkshopDL support --- Dockerfile | 9 ++++++--- README.md | 9 ++++++++- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/Dockerfile b/Dockerfile index fc20f41..de73bbb 100644 --- a/Dockerfile +++ b/Dockerfile @@ -16,8 +16,11 @@ ENV \ # http://steamcommunity.com/dev/managegameservers GLST="" \ # - # Workshop (require API) - WORKSHOPCOLLECTIONID="" \ + # Workshop server download (require API) + WORKSHOP="\${WORKSHOPCOLLECTIONID:-}" \ + # + # Workshop client download (require API) + WORKSHOPDL="" \ # # Server config GAME="garrysmod" \ @@ -35,7 +38,7 @@ ENV \ -tickrate \${TICKRATE} \ -maxplayers \${MAXPLAYERS} \ -authkey \${AUTHKEY} \ - +host_workshop_collection \${WORKSHOPCOLLECTIONID} \ + +host_workshop_collection \${WORKSHOP} \ +gamemode \${GAMEMODE} \ +map \${MAP} \ +servercfgfile \${CONFIG} \ diff --git a/README.md b/README.md index 426bfc8..27dd54e 100644 --- a/README.md +++ b/README.md @@ -67,7 +67,8 @@ docker run -it \ -e "AUTHKEY=..." \ -e "GAMEMODE=terrortown" \ -e "MAP=ttt_minecraft_b5" \ - -e "WORKSHOPCOLLECTIONID=843519054" \ + -e "WORKSHOP=843519054" \ + -e "WORKSHOPDL=843519054" \ -v ./server.cfg:/opt/steam/garrysmod/cfg/server.cfg \ hackebein/garrysmod ``` @@ -94,6 +95,12 @@ MAXPLAYERS: Max players CUSTOMPARAMETERS: additional parameters (`Default: `) +WORKSHOP: downloads workshop collection for server +(`Default: `) + +WORKSHOPDL: downloads workshop collection for client before joining +(`Default: `) + ## More Options You can found more configuration options on the parent image page [hackebein/srcds](https://hub.docker.com/r/hackebein/srcds)