Skip to content

Commit

Permalink
docs: cleanup docs
Browse files Browse the repository at this point in the history
  • Loading branch information
JamesIves committed Jul 15, 2024
1 parent a2ca360 commit ea1412d
Show file tree
Hide file tree
Showing 8 changed files with 33 additions and 106 deletions.
10 changes: 5 additions & 5 deletions config/README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# Configs and Plugins

If you wish to add server configurations, such as add-ons, plugins, map rotations, etc, you can add them to the `config` directory. The `config` directory is volume mapped within the directory for the game you're starting the container for. For example, if you're starting a container for `cstrike`, you can add things like `mapcycle.txt` or `motd.txt` here and it would appear within the corresponding `cstrike` directory on the server.
If you wish to add server configurations, such as add-ons, plugins, map rotations, etc, you can add them to the `config` directory. The `config` directory is volume-mapped within the directory for the game for which you're starting the container. For example, if you're starting a container for `cstrike`, you can add things like `mapcycle.txt` or `motd.txt` here, and it would appear within the corresponding `cstrike` directory on the server.

> [!NOTE]
> The startup examples posted in the project README already have this directory volume mapped accordingly. If you've strayed from the suggested setup, [please refer back to it to get started](../README.md).
> The startup examples posted in the project README already have this directory volume mapped accordingly. If you've strayed from the suggested setup, [please refer back to it to get started](../../README.md).
```
├── hlds
Expand All @@ -15,10 +15,10 @@ If you wish to add server configurations, such as add-ons, plugins, map rotation
```

> [!TIP]
> You can use this method to install server plugins such as AMX Mod, Meta Mod, etc, as the directory can handle nested folders too, for example these can be placed in `config/addons/amxmodx` etc.
> You can use this method to install server plugins such as AMX Mod, Meta Mod, etc., as the directory can handle nested folders too; for example, these can be placed in `config/addons/amxmodx` etc.
1. Create a folder called `config` that lives alongside where you would typically start the server process. If you've cloned this project locally, you'd place them alongside this README file.
1. Create a folder called `config` alongside where you would typically start the server process. If you've cloned this project locally, you'd place it alongside this README file.
2. Add your config files to the directory.
3. Start the image as you normally would, either with `docker run` or `docker compose up`.
3. Start the image as you usually would, either with `docker run` or `docker compose up`.

For a list of all the available server configuration types, [refer to the Valve Developer Wiki](https://developer.valvesoftware.com/wiki/Main_Page).
13 changes: 10 additions & 3 deletions container/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,14 @@ FROM ubuntu:18.04
ARG GAME=valve
ENV GAME ${GAME}

LABEL vendor="jives.dev" \
maintainer="James Ives"
LABEL org.opencontainers.image.title="hlds-docker" \
org.opencontainers.image.description="🐋 📦 Half-Life Dedicated Server powered by Docker. Supports all the classic GoldSrc Half-Life games and mods, including the ability to add custom configurations and plugins." \
org.opencontainers.image.vendor="jamesiv.es" \
org.opencontainers.image.authors="James Ives" \
org.opencontainers.image.licenses="MIT" \
org.opencontainers.image.url="https://github.com/jamesives/hlds-docker" \
org.opencontainers.image.documentation="https://github.com/jamesives/hlds-docker/README.md" \
org.opencontainers.image.source="https://github.com/jamesives/hlds-docker"

RUN dpkg --add-architecture i386 && \
apt-get update && \
Expand All @@ -25,14 +31,15 @@ WORKDIR /opt/steam

COPY ./hlds.txt /opt/steam

# Replace $GAME with the requested mod to install in hlds.txt.
# Replaces $GAME with the requested mod to install in hlds.txt.
RUN sed -i "s/\$GAME/${GAME}/g" /opt/steam/hlds.txt

RUN curl -v -sL media.steampowered.com/client/installer/steamcmd_linux.tar.gz | tar xzvf - && \
file /opt/steam/linux32/steamcmd && \
./steamcmd.sh +runscript /opt/steam/hlds.txt

# Writes the steam_appid.txt file to the hlds directory with the title id for Half-Life.
# Patches a known issue with the Steam client.
RUN mkdir -p $HOME/.steam \
&& ln -s /opt/steam/linux32 $HOME/.steam/sdk32 \
&& echo 70 > /opt/steam/hlds/steam_appid.txt
Expand Down
11 changes: 7 additions & 4 deletions container/config/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# Configs and Plugins

If you wish to add server configurations, such as add-ons, plugins, map rotations, etc, you can add them to the `config` directory. The `config` directory is volume mapped within the directory for the game you're starting the container for. For example, if you're starting a container for `cstrike`, you can add things like `mapcycle.txt` or `motd.txt` here and it would appear within the corresponding `cstrike` directory on the server.
> [!WARNING]
> Configs added here will be included in the distributed image. This means users must override them on startup when using a distributed version.
If you wish to add server configurations, such as add-ons, plugins, map rotations, etc, you can add them to the `config` directory. The `config` directory is volume-mapped within the directory for the game for which you're starting the container. For example, if you're starting a container for `cstrike`, you can add things like `mapcycle.txt` or `motd.txt` here, and it would appear within the corresponding `cstrike` directory on the server.

> [!NOTE]
> The startup examples posted in the project README already have this directory volume mapped accordingly. If you've strayed from the suggested setup, [please refer back to it to get started](../../README.md).
Expand All @@ -15,10 +18,10 @@ If you wish to add server configurations, such as add-ons, plugins, map rotation
```

> [!TIP]
> You can use this method to install server plugins such as AMX Mod, Meta Mod, etc, as the directory can handle nested folders too, for example these can be placed in `config/addons/amxmodx` etc.
> You can use this method to install server plugins such as AMX Mod, Meta Mod, etc., as the directory can handle nested folders too; for example, these can be placed in `config/addons/amxmodx` etc.
1. Create a folder called `config` that lives alongside where you would typically start the server process. If you've cloned this project locally, you'd place them alongside this README file.
1. Create a folder called `config` alongside where you would typically start the server process. If you've cloned this project locally, you'd place it alongside this README file.
2. Add your config files to the directory.
3. Start the image as you normally would, either with `docker run` or `docker compose up`.
3. Start the image as you usually would, either with `docker run` or `docker compose up`.

For a list of all the available server configuration types, [refer to the Valve Developer Wiki](https://developer.valvesoftware.com/wiki/Main_Page).
13 changes: 8 additions & 5 deletions container/mods/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# Custom Mods

If you want to run a custom mod, you can do so with the `mods` directory. The `mods` directory is volume mapped within the root directory of the Half-Life Dedicated Server client on startup. For example, you wanted to add a mod named `decay`, you'd place it as a sub folder here, ie `mods/decay`. Once the container starts it would be placed in the following directory.
> [!WARNING]
> Mods added here will be included in the distributed image. This means users must override them on startup when using a distributed version.
If you want to run a custom mod, you can do so with the `mods` directory. The `mods` directory is volume mapped within the root directory of the Half-Life Dedicated Server client on startup. For example, if you wanted to add a mod named `decay`, you'd place it as a subfolder here, i.e., `mods/decay`. Once the container starts, it would be placed in the following directory.

```
├── hlds
Expand All @@ -19,17 +22,17 @@ If you want to run a custom mod, you can do so with the `mods` directory. The `m
```

> [!NOTE]
> The startup examples posted in the project README already have this directory volume mapped accordingly. If you've strayed from the suggested setup, [please refer back to it to get started](../../README.md).
> The startup examples posted in the project README already have this directory volume mapped accordingly. If you've strayed from the suggested setup, [please refer back to it to get started](../README.md).
1. Create a folder called `mods` that lives alongside where you would normally start the server process. If you've cloned this project locally, you'd place them alongside this README file.
1. Create a folder called `mods` alongside where you would normally start the server process. If you've cloned this project locally, you'd place it alongside this README file.
2. Add your mod files as a sub-directory of `mods`. For example if the mod name is `decay`, you'd place it in `mods/decay`.
3. Define the `GAME` environment variable for your mod name. The dedicated server client will use this to ensure that it starts a server for the correct mod, which corresponds with the directory name that was just created.

```bash
export GAME=decay
```

4. Start the image as you normally would, either with `docker run` or `docker compose up`. Most Half-Life mods require specific startup arguments. For more details, refer to the [Valve Developer Wiki](https://developer.valvesoftware.com/wiki/Half-Life_Dedicated_Server) and the instructions for the mod you're trying to run.
4. Start the image as you usually would, either with `docker run` or `docker compose up`. Most Half-Life mods require specific startup arguments. For more details, refer to the [Valve Developer Wiki](https://developer.valvesoftware.com/wiki/Half-Life_Dedicated_Server) and the instructions for the mod you're trying to run.

> [!TIP]
> When using a pre-built image, you'll likely want to use the `valve` image (`jives/hlds:valve`), but this ultimately depends on the mod.
> When using a pre-built image, you'll likely want to use the `valve` base image (`jives/hlds:valve`).
50 changes: 0 additions & 50 deletions docs/BUILDING_AN_IMAGE.md

This file was deleted.

19 changes: 0 additions & 19 deletions docs/CUSTOM_MODS.md

This file was deleted.

17 changes: 0 additions & 17 deletions docs/SERVER_CONFIGS_AND_PLUGINS.md

This file was deleted.

6 changes: 3 additions & 3 deletions mods/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Custom Mods

If you want to run a custom mod, you can do so with the `mods` directory. The `mods` directory is volume mapped within the root directory of the Half-Life Dedicated Server client on startup. For example, you wanted to add a mod named `decay`, you'd place it as a sub folder here, ie `mods/decay`. Once the container starts it would be placed in the following directory.
If you want to run a custom mod, you can do so with the `mods` directory. The `mods` directory is volume mapped within the root directory of the Half-Life Dedicated Server client on startup. For example, if you wanted to add a mod named `decay`, you'd place it as a subfolder here, i.e., `mods/decay`. Once the container starts, it would be placed in the following directory.

```
├── hlds
Expand All @@ -21,15 +21,15 @@ If you want to run a custom mod, you can do so with the `mods` directory. The `m
> [!NOTE]
> The startup examples posted in the project README already have this directory volume mapped accordingly. If you've strayed from the suggested setup, [please refer back to it to get started](../README.md).
1. Create a folder called `mods` that lives alongside where you would normally start the server process. If you've cloned this project locally, you'd place them alongside this README file.
1. Create a folder called `mods` alongside where you would normally start the server process. If you've cloned this project locally, you'd place it alongside this README file.
2. Add your mod files as a sub-directory of `mods`. For example if the mod name is `decay`, you'd place it in `mods/decay`.
3. Define the `GAME` environment variable for your mod name. The dedicated server client will use this to ensure that it starts a server for the correct mod, which corresponds with the directory name that was just created.

```bash
export GAME=decay
```

4. Start the image as you normally would, either with `docker run` or `docker compose up`. Most Half-Life mods require specific startup arguments. For more details, refer to the [Valve Developer Wiki](https://developer.valvesoftware.com/wiki/Half-Life_Dedicated_Server) and the instructions for the mod you're trying to run.
4. Start the image as you usually would, either with `docker run` or `docker compose up`. Most Half-Life mods require specific startup arguments. For more details, refer to the [Valve Developer Wiki](https://developer.valvesoftware.com/wiki/Half-Life_Dedicated_Server) and the instructions for the mod you're trying to run.

> [!TIP]
> When using a pre-built image, you'll likely want to use the `valve` base image (`jives/hlds:valve`).

0 comments on commit ea1412d

Please sign in to comment.