Skip to content

Latest commit

 

History

History
64 lines (47 loc) · 7.81 KB

README.md

File metadata and controls

64 lines (47 loc) · 7.81 KB

hlds-docker

Docker in the Half-Life Colours

Half-Life Dedicated Server powered by Docker. It supports all the classic GoldSrc Half-Life games and mods, including the ability to add custom configurations and plugins.

Special thank you to all the past and present GitHub Sponsors 💖.

Chooksta69  MattWillFlood  jonathan-milan-pollock  raoulvdberge  robjtede  hadley  kevinchalet  Yousazoe  github  annegentle  planetoftheweb  melton1968  szepeviktor  sckott  provinzkraut  electrovir  Griefed  MontezumaIves  tonjohn  wylie      

Getting Started 🚀

Before starting, ensure you have the Docker daemon and the Docker CLI tool installed and available.

Important

The following steps will not work if you use an ARM architecture system. For best results, use a system running x86-64.

You can run the following in your terminal to get started as quickly as possible. Adjust the image name (jives/hlds) so the tag corresponds with the game you want to use. Additionally, you can adjust the server startup arguments by modifying the command property; for a list of available arguments, visit the Valve Developer Wiki.

docker run -d -ti \
  --name hlds \
  -v "$(pwd)/config:/temp/config" \
  -v "$(pwd)/mods:/temp/mods" \
  -p 27015:27015/udp \
  -p 27015:27015 \
  -p 26900:26900/udp \
  jives/hlds:valve  \
  "+log on +rcon_password changeme +maxplayers 12 +map crossfire" # 📣 Modify your server startup commands here. You can specify the image with the desired game you want the server to run in the line above.

Tip

The available images are below. When changing the game, be sure to adjust the +map parameter, as it may cause the server to not be joinable if the map is unavailable.

Container images are published on Docker Hub and the GitHub Container Registry.

Once the command finishes, you can connect to your server via the public IP address by loading the game on Steam. You must own a copy of the game on Steam to play.

Note

If you cannot join the server, you can check for errors in the server logs by running docker ps to get the container id followed by docker logs <container id>.

Docker Compose

If you'd prefer to configure your server using Docker Compose, you can pull down the project repository to your system and run docker compose up from the root. Make any modifications you need, such as changing the game image and server startup commands in docker-compose.yml before running docker compose up.

Advanced Setup ⚙️

To customize the server client further, please check out the following advanced setup guides.