Docker image for CSGO Server Launcher.
Note
Want to be notified of new releases? Check out 🔔 Diun (Docker Image Update Notifier) project!
Registry | Image |
---|---|
Docker Hub | crazymax/csgo-server-launcher |
GitHub Container Registry | ghcr.io/crazy-max/csgo-server-launcher |
TZ
: The timezone assigned to the container (defaultUTC
)PUID
: csgo-server-launcher user id (default1000
)PGID
: csgo-server-launcher group id (default1000
)SMTP_HOST
: SMTP server host.SMTP_PORT
: SMTP server port. Default25
or465
if TLS.SMTP_TLS
: Enable or disable TLS (also known as SSL) for secured connections (on
oroff
).SMTP_STARTTLS
: Start TLS from within the session (on
, default), or tunnel the session through TLS (off
).SMTP_TLS_CHECKCERT
: Enable or disable checks of the server certificate (on
oroff
). They are enabled by default.SMTP_AUTH
: Enable or disable authentication and optionally choose a method to use. The argumenton
chooses a method automatically.SMTP_USER
: Set the user name for authentication. Authentication must be activated with theSMTP_AUTH
env var.SMTP_PASSWORD
: Set the password for authentication. Authentication must be activated with theSMTP_AUTH
env var.SMTP_DOMAIN
: Argument of theSMTP EHLO
command. Default islocalhost
.SMTP_FROM
: Set the envelope-from address. Supported substitution patterns can be found here.
💡
SMTP_USER_FILE
andSMTP_PASSWORD_FILE
can be used to fill in the value from a file, especially for Docker's secrets feature.
And also the following environment variables to edit the CSGO Server Launcher configuration:
IP
(default$(sudo dig -4 +short myip.opendns.com @resolver1.opendns.com)
)PORT
(default27015
)GSLT
STEAM_LOGIN
(defaultanonymous
)STEAM_PASSWORD
(defaultanonymous
)UPDATE_EMAIL
UPDATE_RETRY
(default3
)CLEAR_DOWNLOAD_CACHE
(default0
)API_AUTHORIZATION_KEY
WORKSHOP_COLLECTION_ID
(default125499818
)WORKSHOP_START_MAP
(default125488374
)MAXPLAYERS
(default18
)TICKRATE
(default64
)EXTRAPARAMS
(default-nohltv +sv_pure 0 +game_type 0 +game_mode 0 +mapgroup mg_active +map de_dust2
)
💡
GSLT_FILE
,STEAM_LOGIN_FILE
,STEAM_PASSWORD_FILE
andAPI_AUTHORIZATION_KEY_FILE
can be used to fill in the value from a file, especially for Docker's secrets feature.
/var/steamcmd/games/csgo
: CSGO root folder/home/steam/Steam
: Steam folder for logs, appcache, etc...
Docker compose is the recommended way to run this image. Copy the content of folder examples/compose in /var/csgo-server-launcher/
on your host for example. Edit the compose and env files with your preferences and run the following command :
$ docker-compose up -d
$ docker-compose logs -f
You can also use the following minimal command:
$ docker run -dt --name csgo --restart always \
--ulimit nproc=65535 \
--ulimit nofile=32000:40000 \
-p ${PORT}:${PORT} \
-p ${PORT}:${PORT}/udp \
--env-file $(pwd)/.env \
-v $(pwd)/csgo:/var/steamcmd/games/csgo \
-v $(pwd)/steam:/home/steam/Steam \
crazymax/csgo-server-launcher:latest
⚠️ ${PORT}
is the CSGO server port defined in your.env
file
You can upgrade this image whenever I push an update:
docker-compose pull
docker-compose up -d
If you use compose, you can update CSGO by using the updater service:
$ docker-compose down # stop csgo
$ docker-compose -f updater.yml up # start updater
$ docker-compose up -d # start csgo
If you don't use compose:
$ docker stop csgo
$ docker run -it --name csgo-updater --restart on-failure \
--env-file $(pwd)/.env \
-v $(pwd)/csgo:/var/steamcmd/games/csgo \
-v $(pwd)/steam:/home/steam/Steam \
crazymax/csgo-server-launcher:latest \
csgo-server-launcher update
$ docker start csgo