Custom HLDS Engine Game
gamesThis option allows modifying the startup arguments and other details to run a custom HLDS based game on the panel.
README
HLDS Servers
This is for older games like CS 1.6 (default game) and other servers that still run on the older HLDS server under id 90
Server Ports
HLDS servers require up to 6 ports
| Port | default |
|---|---|
| Game/rcon | 27015 |
| HLTV | 27020 |
| VAC | 26900 |
Docker Images (1)
| Name | Image |
|---|---|
ghcr.io/ptero-eggs/games:source | ghcr.io/ptero-eggs/games:source |
Startup Command
./hlds_run -console -game {{HLDS_GAME}} -port {{SERVER_PORT}} -sport {{VAC_PORT}} +map {{SRCDS_MAP}} +ip 0.0.0.0 -strictportbind -norestart Variables (9)
Game ID
The ID corresponding to the game to download and run using HLDS. The HLDS server ID is 90. This should not be changed.
- Environment:
SRCDS_APPID- Default:
90- User Viewable:
- ❌
- User Editable:
- ❌
- Rules:
required|numeric|in:90
Game Name
The name corresponding to the game to download and run using HLDS. all the HLDS server names are here - https://developer.valvesoftware.com/wiki/Dedicated_Server_Name_Enumeration
- Environment:
HLDS_GAME- Default:
cstrike- User Viewable:
- ❌
- User Editable:
- ❌
- Rules:
required|alpha_dash|between:1,100
Map
The default map for the server.
- Environment:
SRCDS_MAP- Default:
de_dust2- User Viewable:
- ❌
- User Editable:
- ❌
- Rules:
required|string|alpha_dash
VAC port
Specifies the VAC port the server should use. Default is 26900.
- Environment:
VAC_PORT- Default:
26900- User Viewable:
- ❌
- User Editable:
- ❌
- Rules:
required|numeric|digits_between:1,5
Steam Username
Steam account used to download files (Defaults to anonymous)
- Environment:
STEAM_USER- Default:
None- User Viewable:
- ❌
- User Editable:
- ❌
- Rules:
nullable|string|max:32
Steam Password
Password for Steam account
- Environment:
STEAM_PASS- Default:
None- User Viewable:
- ❌
- User Editable:
- ❌
- Rules:
nullable|string|max:64
Steam Auth
Steam Guard 2FA code for account
- Environment:
STEAM_AUTH- Default:
None- User Viewable:
- ❌
- User Editable:
- ❌
- Rules:
nullable|string|max:20
Beta branch
Leave empty for the public branch, for the legacy version select steam_legacy.
- Environment:
SRCDS_BETAID- Default:
None- User Viewable:
- ❌
- User Editable:
- ❌
- Rules:
nullable|string|in:,steam_legacy
Auto update
Auto update on restart
- Environment:
AUTO_UPDATE- Default:
0- User Viewable:
- ❌
- User Editable:
- ❌
- Rules:
required|boolean
Installation Script
ghcr.io/ptero-eggs/installers:debianbash#!/bin/bash
# SRCDS Base Installation Script
#
# Server Files: /mnt/server
# just in case someone removed the defaults.
if [[ "${STEAM_USER}" == "" ]] || [[ "${STEAM_PASS}" == "" ]]; then
echo -e "steam user is not set.\n"
echo -e "Using anonymous user.\n"
STEAM_USER=anonymous
STEAM_PASS=""
STEAM_AUTH=""
else
echo -e "user set to ${STEAM_USER}"
fi
## download and install steamcmd
cd /tmp
mkdir -p /mnt/server/steamcmd
curl -sSL -o steamcmd.tar.gz https://steamcdn-a.akamaihd.net/client/installer/steamcmd_linux.tar.gz
tar -xzvf steamcmd.tar.gz -C /mnt/server/steamcmd
mkdir -p /mnt/server/steamapps # Fix steamcmd disk write error when this folder is missing
cd /mnt/server/steamcmd
# SteamCMD fails otherwise for some reason, even running as root.
# This is changed at the end of the install process anyways.
chown -R root:root /mnt
export HOME=/mnt/server
## install game using steamcmd
./steamcmd.sh +force_install_dir /mnt/server +login ${STEAM_USER} ${STEAM_PASS} ${STEAM_AUTH} +app_set_config 90 mod ${HLDS_GAME} $( [[ "${WINDOWS_INSTALL}" == "1" ]] && printf %s '+@sSteamCmdForcePlatformType windows' ) +app_update ${SRCDS_APPID} $( [[ -z ${SRCDS_BETAID} ]] || printf %s "-beta ${SRCDS_BETAID}" ) $( [[ -z ${SRCDS_BETAPASS} ]] || printf %s "-betapassword ${SRCDS_BETAPASS}" ) ${INSTALL_FLAGS} validate +quit
## set up 32 bit libraries
mkdir -p /mnt/server/.steam/sdk32
cp -v linux32/steamclient.so ../.steam/sdk32/steamclient.so
## set up 64 bit libraries
mkdir -p /mnt/server/.steam/sdk64
cp -v linux64/steamclient.so ../.steam/sdk64/steamclient.so
## install end
echo "-----------------------------------------"
echo "Installation completed..."
echo "-----------------------------------------"