For over two decades, Counter-Strike has offered an elite competitive experience, one shaped by millions of players from across the globe. And now the next chapter in the CS story is about to begin. This is Counter-Strike 2.
Steam Description : For over two decades, Counter-Strike has offered an elite competitive experience, one shaped by millions of players from across the globe. And now the next chapter in the CS story is about to begin. This is Counter-Strike 2.
For CS2 Valve has decided to merge the game and server files. There will not be standalone dedicated server files.
Minimum | Recommended | |
---|---|---|
Processor | minim x86-64-v2 (with popcnt) | --- |
RAM | 2 GB | --- |
Storage | 33 GB | --- |
Ports required to run the server in a table format.
Port | default |
---|---|
Game | 27015 |
Source TV (Optional) | 27020 |
RCON is only accessible from external apps, NOT from the game client itself. It's broken in CS2.
If possible always use the Pterodactyl console to use your commands like map de_nuke
or mp_restartgame 3
.
Further install instructions can be found at the official Documentation.
Name | Tag |
---|---|
ghcr.io/ptero-eggs/steamcmd:sniper | ghcr.io/ptero-eggs/steamcmd:sniper |
Name | Description | Environment Variable | Default Value | User Viewable | User Editable |
---|---|---|---|---|---|
Map | The default map for the server. Examples: Bomb: de_dust2, de_mirage, de_nuke, de_overpass, de_inferno, de_ancient, de_vertigo, de_anubis Hostage: cs_italy, cs_office Arms Race: ar_baggage, ar_shoots | SRCDS_MAP | de_dust2 | Yes | Yes |
Source AppID | Required for game to update on server restart. Do not modify this. | SRCDS_APPID | 730 | No | No |
Max Players | Specifies the maximum amount of players that are able to join the server. | MAX_PLAYERS | 12 | Yes | Yes |
Auto-update server | This is to enable / disable auto-updating your server on restart. By default this is set to enabled. | AUTO_UPDATE | 1 | Yes | Yes |
SourceTV Port | SourceTV port used for connections to spectates games on your server. | TV_PORT | 27020 | Yes | No |
Steam Gameserver Login Token | The Steam Account Token required for the server to be displayed public. The token can be acquired here: https://steamcommunity.com/dev/managegameservers | STEAM_GSLT | Yes | Yes | |
Enable VAC | Enable / Disable VAC (Valve Anti Cheat) on your server. By default this will be enabled. | VAC_ENABLED | 1 | Yes | Yes |
Enable RCON | Enable / Disable RCON for using RCON commands with external tools. By default this will be disabled. | RCON_ENABLED | 0 | Yes | Yes |
Server Name | Sets the server name listed in the steam server browser. | SERVER_NAME | A Pterodactyl hosted CS2 Server | Yes | Yes |
Server Password | If specified, players must provide this password to join the server. | SERVER_PASSWORD | Yes | Yes | |
RCON Password | To gain access to administrator commands on the server. | RCON_PASSWORD | Yes | Yes | |
Gamemode | Defines the Gamemode and Gametype to be set at the start of the next round. Examples: Competitive: game_mode 1 game_type 0 Wingman: game_mode 2 game_type 0 Casual: game_mode 0 game_type 0 Deathmatch: game_mode 2 game_type 1 Arms Race: game_mode 0 game_type 1 Custom: game_mode 0 game_type 3 | GAME_MODE | 1 | Yes | Yes |
Gametype | Defines the Gamemode and Gametype to be set at the start of the next round. Examples: Competitive: game_mode 1 game_type 0 Wingman: game_mode 2 game_type 0 Casual: game_mode 0 game_type 0 Deathmatch: game_mode 2 game_type 1 Arms Race: game_mode 0 game_type 1 Custom: game_mode 0 game_type 3 | GAME_TYPE | 0 | Yes | Yes |
#!/bin/bash
# steamcmd Base Installation Script
#
# Server Files: /mnt/server
# Image to install with is 'ghcr.io/ptero-eggs/installers:debian'
## 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_update ${SRCDS_APPID} ${EXTRA_FLAGS} validate +quit ## other flags may be needed depending on install. looking at you cs 1.6
## 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 "-----------------------------------------"