$ git clone https://github.com/h3ct0r/counter-strike-docker
$ make build
Login and create a token at: https://steamcommunity.com/dev/managegameservers This token is not mandatory, but using it will enable adding your server to the Steam server list so others can join and play without too much hazzle.
- UDP/TCP 27015 - Main connection port (MUST). This is the port and protocol used by the server browser, allows clients to connect. TCP is used for in-game RCON
- UDP 27020 - SourceTV (if enabled). You can disable this port by adding "-nohltv" to the start up command.
- UDP 27005 - This is an outgoing connection used by clients. Typically you would not need to open this port in your firewall because this is for OUTBOUND connections.
$ docker run -d -p 27005-27020:27005-27020/udp -p 27005-27020:27005-27020 -e MAXPLAYERS=16 -e START_MAP=de_dust2 -e ADMIN_STEAM={YOUR_STEAM_ID} -e SERVER_NAME="{YOUR_GAME_SERVER_NAME}" --name cs counter_strike_16:latest +sv_setsteamaccount {YOUR_SERVER_TOKEN} +sv_password {YOUR_GAME_PASSWORD} +rcon_password {YOUR_REMOTE_COMMAND_PASSWORD} +sv_lan 0
- MAXPLAYERS : maximum number of players for this game session.
- START_MAP : the map that will be used when game starts.
- ADMIN_STEAM : your steam_id. This setting will allow the user of the defined steam_id to control the server. The steam_id can be found using the comand
status
in the game console. Add this id without the 'STEAM_' part. Example: '0:1:22545666'. - SERVER_NAME : the name of game the server displayed to the players.
- +sv_setsteamaccount : the token from the developer server account. This in theory allows this server to be displayed into the server list in Steam. It is recommended from the Steam tutorial, but dont know if this is obligatory.
- +sv_password : the password of your game session. The users will need to set this password to enter the game.
- +rcon_password : the remote administrator password for this game instance. The RCON command list can be seen in https://github.com/h3ct0r/counter-strike-docker/wiki/RCON-Commands
- +sv_lan: allow remote conections outside your LAN
docker stop cs
docker start cs
docker rm cs
From the Counter Strike console (press ')
connect 127.0.0.1:27015; password server_password
From the console (inside the game press ') set the environment variable _pbadminpw:
setinfo _pbadminpw "your_password"
Then activate the podbot menu:
pb menu
Use image from Docker Hub:
$ docker run -d -p 27005-27020:27005-27020/udp -p 27005-27020:27005-27020 -e MAXPLAYERS=16 -e START_MAP=de_dust2 -e ADMIN_STEAM=YOUR_ADMIN_STEAM_ID -e SERVER_NAME="TEST SERVER DE_DUST2 ROLF" --name cs h3ct0rxxx/counter_strike_16:latest +sv_setsteamaccount YOUR_STEAM_TOKEN_ID +sv_password YOUR_GAME_PASSWORD +rcon_password YOUR_RCON_PASSWORD +sv_lan 0 +log
- Write MORE Tests
- Add more interesting plugins
- Add sounds?!
- Add fast server for game assets
Apache2
Free Software, Hell Yeah!