CS 1.6 ReHLDS binaries egg. ReHLDS is a reverse-engineered, optimized version of HLDS. Developed by third-party modders to improve stability, performance, and security. Fully compatible with MetaMod, AMX Mod X, and other plugins. Included modules are rehlds, reunion, amxmodx, metamod-r, reapi and ReGameDLL_CS
Counter-Strike 1.6 ReHLDS (Reverse Engineered Half-Life Dedicated Server) is an optimized and updated version of the original HLDS, designed for stability, performance, and security. It provides a modern platform for hosting Counter-Strike 1.6 servers with improved support for custom plugins and modules.
This egg offers everything you need to set up a Counter-Strike 1.6 server using ReHLDS, MetaMod-R, AMX Mod X, and other popular tools.
Component | Minimum | Recommended |
---|---|---|
Processor | - | - |
RAM | 1 GB | 2 GB |
Storage | 2 GB | 5 GB |
Ports required to run the server in a table format.
Port | default |
---|---|
Game | 27015 |
Source TV | 27020 |
Client | 27005 |
Steam | 26900 |
27015 is the default port, but any port can be used. The only required port is the Game port, server can run perfectly fine without other allocations.
server.cfg
, listip.cfg
, and banned.cfg
.For further configuration or plugin information, refer to the official AMX Mod X documentation or the ReHLDS GitHub repository.
Name | Tag |
---|---|
ghcr.io/ptero-eggs/games:source | ghcr.io/ptero-eggs/games:source |
Name | Description | Environment Variable | Default Value | User Viewable | User Editable |
---|---|---|---|---|---|
ReHLDS Version | The version of ReHLDS to install, or 'latest' for the latest release. | VERSION | latest | No | No |
Available Modules | Available Modules: rehlds, reunion, amxmodx, metamod-r, reapi and ReGameDLL_CS | INSTALL_MODULES | rehlds,reunion,amxmodx,metamod-r,reapi,ReGameDLL_CS | Yes | Yes |
Server Hostname | This sets the hostname of the server. Example: "My Custom CS 1.6 Server" | HOSTNAME | Counter-Strike 1.6 Server | Yes | Yes |
Map | The default map for the server. | SRCDS_MAP | de_dust2 | Yes | Yes |
Auto update | Auto update on restart | AUTO_UPDATE | 0 | No | No |
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. | SRCDS_APPID | 90 | No | No |
Game Name | The name corresponding to the game to download and run using HLDS | HLDS_GAME | cstrike | No | No |
Beta branch | Leave empty for the public branch, for the legacy version select steam_legacy. | SRCDS_BETAID | steam_legacy | No | No |
VAC port | Specifies the VAC port the server should use. Default is 26900. | VAC_PORT | 26900 | No | No |
Validate | Validate game files on update. Keep it disabled with ReHLDS due to SteamCMD overwriting its changes | VALIDATE | 0 | No | No |
#!/bin/bash
if [[ -z "${STEAM_USER}" ]] || [[ -z "${STEAM_PASS}" ]]; then
echo -e "Steam user is not set.\nUsing anonymous user."
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
cd /mnt/server/steamcmd
chown -R root:root /mnt
export HOME=/mnt/server
# Install game via 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
mkdir -p /mnt/server/.steam/sdk32
cp -v linux32/steamclient.so ../.steam/sdk32/steamclient.so
mkdir -p /mnt/server/.steam/sdk64
cp -v linux64/steamclient.so ../.steam/sdk64/steamclient.so
cd /mnt/server
# Download repo etc
REPO_OWNER="Red-Banana-Official"
REPO_NAME="cstrike1.6_rehlds"
RELEASE_DATA=$(curl -s https://api.github.com/repos/$REPO_OWNER/$REPO_NAME/releases/latest)
TAG_NAME=$(echo "$RELEASE_DATA" | jq -r '.tag_name')
[[ "$TAG_NAME" == "null" ]] && TAG_NAME="1.0.0"
DOWNLOAD_URL=$(echo "$RELEASE_DATA" | jq -r '.zipball_url')
OUTPUT_FILE="$REPO_NAME-$TAG_NAME.zip"
rm -rf ${REPO_OWNER}-*
echo "Downloading release: $OUTPUT_FILE"
curl -sSL -o "$OUTPUT_FILE" "$DOWNLOAD_URL" || { echo "Failed to download $OUTPUT_FILE"; exit 1; }
echo "Downloaded: $OUTPUT_FILE"
echo "-----------------------------------------"
unzip -q -o "$OUTPUT_FILE"
rm -f "$OUTPUT_FILE"
EXTRACTED_DIR=$(find . -maxdepth 1 -type d -name "${REPO_OWNER}-*" | head -n 1)
cd "$EXTRACTED_DIR"
# Module install
install_module() {
local NAME=$1
local DIR=$2
ZIP=$(find modules/$DIR/ -type f -name '*.zip' | sort -V | tail -n 1)
if [[ -z "$ZIP" ]]; then
echo "Error: ZIP file for module '$NAME' not found."
return 1
fi
echo "Installing module: $NAME"
mkdir -p "${NAME}-install"
cp "$ZIP" "${NAME}-install"
cd "${NAME}-install"
unzip -q -o *.zip
case "$NAME" in
"rehlds"|"ReGameDLL_CS")
cp -r bin/linux32/* /mnt/server
;;
"amxmodx"|"reapi")
cp -r addons /mnt/server/cstrike
;;
"metamod-r")
cp -r addons /mnt/server/cstrike
mkdir -p /mnt/server/cstrike/addons/metamod
touch /mnt/server/cstrike/addons/metamod/plugins.ini
grep -qxF "linux addons/amxmodx/dlls/amxmodx_mm_i386.so" /mnt/server/cstrike/addons/metamod/plugins.ini || echo "linux addons/amxmodx/dlls/amxmodx_mm_i386.so" >> /mnt/server/cstrike/addons/metamod/plugins.ini
sed -i 's|^gamedll_linux.*|gamedll_linux "addons/metamod/metamod_i386.so"|' /mnt/server/cstrike/liblist.gam || echo 'gamedll_linux "addons/metamod/metamod_i386.so"' >> /mnt/server/cstrike/liblist.gam
;;
"reunion")
mkdir -p /mnt/server/cstrike/addons/metamod/reunion/
cp -r bin/Linux/* /mnt/server/cstrike/addons/metamod/reunion/
touch /mnt/server/cstrike/addons/metamod/plugins.ini
grep -qxF "linux addons/metamod/reunion/reunion_mm_i386.so" /mnt/server/cstrike/addons/metamod/plugins.ini || echo "linux addons/metamod/reunion/reunion_mm_i386.so" >> /mnt/server/cstrike/addons/metamod/plugins.ini
cp reunion.cfg /mnt/server/cstrike/reunion.cfg
SALT=$(tr -dc 'A-Za-z0-9' < /dev/urandom | head -c 50)
sed -i "s/^SteamIdHashSalt\s*=.*/SteamIdHashSalt = $SALT/" /mnt/server/cstrike/reunion.cfg
;;
esac
cd ..
rm -rf "${NAME}-install"
echo "Module '$NAME' installed successfully."
}
declare -A MODULES=(
["rehlds"]="rehlds"
["amxmodx"]="amxmodx"
["ReGameDLL_CS"]="ReGameDLL_CS"
["reapi"]="reapi"
["metamod-r"]="metamod-r"
["reunion"]="reunion"
)
IFS=',' read -r -a MODULE_LIST <<< "${INSTALL_MODULES}"
for mod in "${MODULE_LIST[@]}"; do
[[ -n "${MODULES[$mod]}" ]] && install_module "$mod" "${MODULES[$mod]}"
done
# Ensure files exist
mkdir -p /mnt/server/cstrike/addons/amxmodx/data
[[ ! -f /mnt/server/cstrike/listip.cfg ]] && echo "// Banned IPs" > /mnt/server/cstrike/listip.cfg
[[ ! -f /mnt/server/cstrike/banned.cfg ]] && echo "// Banned IDs" > /mnt/server/cstrike/banned.cfg
[[ ! -f /mnt/server/cstrike/addons/amxmodx/data/csstats.dat ]] && touch /mnt/server/cstrike/addons/amxmodx/data/csstats.dat
chmod -R 777 /mnt/server
rm -rf /mnt/server/Red-Banana-Official-*
echo "-----------------------------------------"
echo "Installation Complete!"
echo "-----------------------------------------"