Skip to content

Commit

Permalink
Updated instructions and Docker Compose file
Browse files Browse the repository at this point in the history
  • Loading branch information
SNMetamorph committed Oct 30, 2024
1 parent a86ea92 commit 8edad1d
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 16 deletions.
34 changes: 20 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,29 +3,35 @@
![banner](banner.png)

# Xash3D FWGS Dedicated Server Docker
Probably, the fastest and easiest way to set up an old-school Xash3D FWGS
Half-Life Deathmatch Dedicated Server. You don't need to know
anything about Linux or XashDS to start a server. You just need installed Docker and this image.
Probably, the fastest and easiest way to set up an old-school Xash3D FWGS dedicated server. You don't need to know anything about Linux or XashDS to start a server. You just need PC or VDS with installed Linux and installed Docker on it.

## Supported mods
We have plans to support more mods in the future. But currently, only Half-Life Deathmatch is supported.

## Quick Start
> **Note:** At the moment, we don't yet publishing pre-built images on Docker Hub. Therefore, you need to build it yourself.
Clone this repository. Just two commands.

```bash
git clone https://github.com/FWGS/xashds-docker.git
cd xashds-docker
```

At the moment, we do not yet publishing pre-built images on Docker Hub. Therefore, you need to build it yourself with this command.

### Building XashDS image manually
Clone this repository and build image with Docker Compose. Just two commands.
In future, when we will publish pre-built images on Docker Hub, this step can be skipped.

```bash
git clone https://github.com/FWGS/xashds-docker.git && cd xashds-docker
sudo docker compose build
sudo docker build --no-cache -t snmetamorph/xashds-hldm:latest .
```

Next, you can use this Compose file below as a base for your custom configuration. If you don't need custom configuration - just ignore it and continue to next step.
Next, you can use this Docker Compose file below as a base for your custom configuration. If you don't need custom configuration - just use this preset and continue to next step.

```yaml
services:
xashds:
image: xashdsdocker:latest
image: snmetamorph/xashds-hldm:latest
build: .
container_name: xashds
container_name: xashds-hldm
restart: always
tty: true
stdin_open: true
Expand All @@ -34,7 +40,7 @@ services:
- '27015:27015/udp'
```
> **Note:** Any [server config command](http://sr-team.clan.su/K_stat/hlcommandsfull.html)
> **Note:** any [server config command](http://sr-team.clan.su/K_stat/hlcommandsfull.html)
can be passed to `command` section in Docker Compose file.

By default, server will start on 27015 UDP port. When you're finished with configuration and ready to start a server just run:
Expand All @@ -43,9 +49,9 @@ By default, server will start on 27015 UDP port. When you're finished with confi
sudo docker compose up -d
```

After that, server will automatically start on system startup and auto-restarting in case of crash.
After that, Docker container with XashDS will be created and server will automatically start on system startup and auto-restarting in case of crash.

If you want to stop a server and completely remove all containers, run:
If you want to stop a server and completely remove all XashDS containers, run:
```bash
sudo docker compose down
```
Expand Down
4 changes: 2 additions & 2 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
services:
xashds:
image: xashdsdocker:latest
image: snmetamorph/xashds-hldm:latest
build: .
container_name: xashds
container_name: xashds-hldm
restart: always
tty: true
stdin_open: true
Expand Down

0 comments on commit 8edad1d

Please sign in to comment.