Family and friends home for the holidays? Host a ScoutzKnivez LAN night. Holiday setup →

CS 1.6 ScoutzKnivez Server

Containerized Counter-Strike 1.6 scoutzknivez server using the ReHLDS stack

// Install

curl -fsSL https://raw.githubusercontent.com/KevinTCoughlin/cs-server/main/install.sh | bash

Requires Podman (rootless) or Docker. The script pulls the image from ghcr.io, writes config files to ~/.config/cs-server/ (including a random RCON password), and starts the server on port 27015. With Podman it installs a systemd Quadlet unit; with Docker it creates a container with a restart policy.

// Quick Connect

Console Command
connect <your-ip>:27015

Default port: 27015 (UDP + TCP). Replace <your-ip> with your server's LAN or public IP.

// Ready Before the Holiday Break

Christmas, New Year, winter or summer holidays: wherever you are, the break is when everyone is finally in one place. Set it up once for a LAN night with family and friends.

  1. Install it on a spare Linux machineRun the install command above on any box with Podman or Docker. The three ScoutzKnivez maps are in the image, so there is nothing else to download.
  2. Everyone connects from the CS 1.6 consoleOpen the console and type connect <server-lan-ip>:27015. The installer prints the address when it finishes.
  3. Keep it to the houseFor a LAN-only night with the Podman install, change Environment=LAN_MODE=0 to 1 in ~/.config/containers/systemd/scoutzknivez.container, then run systemctl --user daemon-reload && systemctl --user restart scoutzknivez.
  4. Or let friends join from their housesLeave LAN_MODE=0 (the default), allow 27015 UDP and TCP through the host firewall, forward it on your router, and share your public IP.
  5. Only two of you? Bots fill inZBots fill the server up to 10 players and leave as people join, so even a small group gets a full round. Set BOTS=0 to turn them off.
  6. Switch it upType rtv in chat to vote for a new map. For classic Dust 2, set MAP=de_dust2 and MAPCYCLE=mapcycle-dust2.txt in the same unit file and restart.

// Stack

  • ReHLDS3.15.0.896Reverse-engineered HLDS engine
  • ReGameDLL_CS5.30.0.814Reverse-engineered game DLL
  • Metamod-R1.3.0.149Plugin loader
  • AMX Mod X1.10.0 (build 5487)Server-side scripting platform
  • ReAPI5.29.0.358Extended API for ReHLDS/ReGameDLL

// Quick Start

Option 1: Pull from ghcr.io (fastest — pre-built image)

$ podman pull ghcr.io/kevintcoughlin/cs-server:latest
$ podman run -d -p 27015:27015/udp -p 27015:27015/tcp \
  --name scoutzknivez ghcr.io/kevintcoughlin/cs-server:latest

Option 2: Build from source (if you need custom maps/configs)

  1. Clone the repository
  2. Optional: add custom .bsp maps to maps/. The default ScoutzKnivez maps are already bundled from docs/cstrike/maps/
  3. Build and launch the server
$ git clone https://github.com/KevinTCoughlin/cs-server.git
$ cd cs-server
# optional: copy custom .bsp maps into maps/
$ podman compose up --build

// Plugins

  • ScoutzKnivezAuto-strips weapons, gives scout + knife on spawn
  • Auto BhopHold jump to bunny hop — essential for low-gravity
  • Quake SoundsAQS v8.0 — kill streaks, headshots, knife kills with HUD messages. Toggle: !sounds. Sound files are not included (copyright); see the README to add them
  • Rock the VoteType rtv to start a map vote, nominate <map> to add maps
  • AFK KickerOnce 4 or more people are playing, idle players move to spectator after 60 seconds and are kicked after 3 minutes
  • High Ping KickerWarns then kicks players over 150 ms average ping
  • AdvertisementsRotating server info and command hints in chat
  • Website BotSpectator bot in the scoreboard showing the server website URL. Leaves when the server is within 2 slots of full
  • Anti-FloodChat spam prevention (built into AMX Mod X)

// Game Settings

SettingValueEffect
sv_gravity240Low gravity (default 800)
sv_airaccelerate100High air control
mp_freezetime0No freeze on round start
mp_buytime0No buy menu
mp_roundtime33 minute rounds
mp_startmoney16000Max starting money (unused, no buy menu)

// Environment Variables

VariableDefaultDescription
MAPscoutzknivezStarting map name
MAXPLAYERS20Maximum player slots (1–32)
PORT27015Server listen port
BOTS1Enable bots (1=on, 0=off)
LAN_MODE0LAN-only server (1) or public (0)
MAPCYCLEmapcycle.txtMap rotation file, e.g. mapcycle-dust2.txt
NOMASTER0Skip the master server (1=on). For Docker Desktop on Windows

// Bots

Bots are enabled by default using ReGameDLL_CS's built-in ZBot support. Bots fill the server up to 10 players and leave as humans join — no human player required to start.

CvarValueEffect
bot_quota10Players to keep in the game (bots + humans in fill mode)
bot_quota_modefillBots fill empty slots; leave as humans join
bot_difficulty1Normal difficulty
bot_join_after_player0Bots join immediately
bot_auto_vacate1Bots leave to make room for humans

// Windows (WSL2)

Docker Desktop for Windows cannot reliably forward UDP game traffic. Run the server inside a WSL2 Debian distro with Podman or Docker CE instead.

  1. Install Debian: wsl --install Debian
  2. Install dependencies (i386 libs, curl, unzip)
  3. Install Podman or Docker CE in the distro, then run the install script inside WSL2
  4. Find WSL2 IP: ip addr show eth0
  5. Connect from Windows: connect <wsl2-ip>:27015

See README for full instructions. Related: #18

// Production (Quadlet)

Run as a rootless Podman Quadlet unit managed by systemd for auto-start, crash recovery, and graceful shutdown. The one-line installer sets this up with the prebuilt image. From a clone, with a locally built image:

$ podman compose up --build -d && podman compose down
$ mkdir -p ~/.config/cs-server && cp config/server.cfg config/mapcycle*.txt ~/.config/cs-server/
$ just install  # copies the unit, runs daemon-reload
$ systemctl --user start scoutzknivez

To start on boot, run loginctl enable-linger for your user.

On shutdown, players see a 30-second countdown before the server stops cleanly.

// Security

  • No capabilitiesAll Linux capabilities dropped
  • No privilege escalationno-new-privileges enforced, setuid/setgid bits stripped
  • Nologin userSystem user with /usr/sbin/nologin shell
  • Resource limits512 MB memory, 2 CPU cores max
  • Query rate limitingAnti-amplification via sv_max_queries_sec
  • RCON lockout5 failures = 60 min ban

// FastDL

Custom maps (and Quake sounds, if you add them) are served from this site via HTTP for fast client downloads. The repository's config/server.cfg, which is also baked into the image, sets sv_downloadurl to this URL. The one-line installer writes its own server.cfg without it, so add the line there if you want FastDL.

FastDL URL
https://kevintcoughlin.com/cs-server/cstrike/

// Source

View on GitHub Sponsor on GitHub