RCON CLI tool for Source engine game servers (CS2, TF2, Rust, etc.).
Requirements: CMake 3.20+, Ninja, Clang (C++20)
cmake -G Ninja -B build -DCMAKE_CXX_COMPILER=clang++
ninja -C build
# Binary: build/bin/rconcliOr use clang if your system uses it for C++:
cmake -G Ninja -B build -DCMAKE_CXX_COMPILER=clang
ninja -C buildDefault config path: $HOME/.config/rconcli/rconcli.config
Section headers are server names. Use -s/--server to select one (default: default).
Example config (TOML format):
[default]
host = "127.0.0.1"
port = 27015
password = "your_rcon_password"
[production]
host = "prod.example.com"
port = 27015
password = "prod_password"rconcli [OPTIONS] [command...]
rconcli config list [-s server]
rconcli config set serverName address [password]
Options:
-c, --config Config file path (overrides default)
-s, --server Server config to use (default: default)
-a, --address Server address (host or host:port) - overrides config
-p, --password RCON password - overrides config
Environment variables RCON_SERVER, RCON_ADDRESS, and RCON_PASSWORD also override config.
Run with no arguments to show help. Pass a command to execute it via RCON:
rconcli # Show help
rconcli status # Execute "status" on default server
rconcli -s production status # Use "production" server config
rconcli -a 127.0.0.1:27015 -p mypass say Hello # Override address/password
rconcli -c ~/my.config status # Use custom config file
# Config management
rconcli config list # List all servers
rconcli config list -s default # List specific server
rconcli config set default 127.0.0.1:27015 mypass # Add/update server
rconcli config set prod server.com:27015 # Password optional