feat: overhaul server automation, files editor, and CS2 setup workflows

This commit is contained in:
2026-02-26 21:01:00 +00:00
parent 44c439e2f9
commit 2a3ad5e78f
40 changed files with 4675 additions and 468 deletions
+56 -12
View File
@@ -91,14 +91,13 @@ async function seed() {
{
slug: 'cs2',
name: 'Counter-Strike 2',
dockerImage: 'cm2network/csgo:latest',
dockerImage: 'cm2network/cs2:latest',
defaultPort: 27015,
startupCommand:
'./srcds_run -game csgo -console -usercon +game_type 0 +game_mode 0 +mapgroup mg_active +map de_dust2',
startupCommand: '',
stopCommand: 'quit',
configFiles: [
{
path: 'csgo/cfg/server.cfg',
path: 'game/csgo/cfg/server.cfg',
parser: 'keyvalue',
editableKeys: [
'hostname',
@@ -109,21 +108,66 @@ async function seed() {
'mp_limitteams',
],
},
{ path: 'csgo/cfg/autoexec.cfg', parser: 'keyvalue' },
{ path: 'game/csgo/cfg/autoexec.cfg', parser: 'keyvalue' },
],
automationRules: [
{
id: 'cs2-install-latest-metamod',
event: 'server.install.completed',
enabled: true,
runOncePerServer: true,
continueOnError: false,
actions: [
{
id: 'install-cs2-metamod',
type: 'http_directory_extract',
indexUrl: 'https://mms.alliedmods.net/mmsdrop/2.0/',
assetNamePattern: '^mmsource-2\\.0\\.0-git\\d+-linux\\.tar\\.gz$',
destination: '/game/csgo',
stripComponents: 0,
maxBytes: 256 * 1024 * 1024,
},
],
},
{
id: 'cs2-install-latest-counterstrikesharp-runtime',
event: 'server.install.completed',
enabled: true,
runOncePerServer: true,
continueOnError: false,
actions: [
{
id: 'install-cs2-runtime',
type: 'github_release_extract',
owner: 'roflmuffin',
repo: 'CounterStrikeSharp',
assetNamePatterns: [
'^counterstrikesharp-with-runtime-.*linux.*\\.zip$',
'^counterstrikesharp-with-runtime.*\\.zip$',
],
destination: '/game/csgo',
stripComponents: 0,
maxBytes: 256 * 1024 * 1024,
},
],
},
],
environmentVars: [
{
key: 'SRCDS_TOKEN',
default: '',
description: 'Steam Game Server Login Token',
required: true,
description: 'Steam Game Server Login Token (optional for local testing)',
required: false,
},
{ key: 'SRCDS_RCONPW', default: '', description: 'RCON password', required: false },
{ key: 'SRCDS_PW', default: '', description: 'Server password', required: false },
{ key: 'CS2_SERVERNAME', default: 'GamePanel CS2 Server', description: 'Server name', required: false },
{ key: 'CS2_PORT', default: '27015', description: 'Game port', required: false },
{ key: 'CS2_STARTMAP', default: 'de_dust2', description: 'Initial map', required: false },
{ key: 'CS2_MAXPLAYERS', default: '16', description: 'Max players', required: false },
{ key: 'CS2_RCONPW', default: '', description: 'RCON password', required: false },
{
key: 'SRCDS_MAXPLAYERS',
default: '16',
description: 'Max players',
key: 'CS2_IP',
default: '0.0.0.0',
description: 'Bind address',
required: false,
},
],