sidecar.toml
The rust-link sidecar’s configuration. Like every sidecar on this platform it is small on purpose: the sidecar forwards, and policy lives on the site where an administrator can see it. One file per Rust server, because one sidecar serves one server.
The file is written, not shipped
Section titled “The file is written, not shipped”The sidecar writes its config on first run if there is none, with a generated auth token, and
nothing is compiled into the binary. rust-link-sidecar --print-config --config <file> resolves
the config exactly as a start would — writing it and generating the token if needed — and prints
the result, token included, which is the point.
Which file: --config <file>, else $RUSTLINK_CONFIG, else sidecar.toml in the working
directory. Relative paths resolve beside the config file, not the working directory, so a
database configured as rust-link.db lives next to its config wherever the service manager
started it. The installer’s files are under /etc/runicgateway/rust/, or
%ProgramData%\RunicGateway\rust\ on Windows; the egg’s is rust-link/sidecar.toml in the server’s
directory.
The keys
Section titled “The keys”| Key | What it is for |
|---|---|
game.bind | Loopback address the bridge plugin dials. Never move it off loopback |
game.server_id | A cross-check against the id the plugin announces. A plugin naming another server is refused before anything it sent is stored |
web.bind | Address the website reaches the sidecar on |
web.auth_token | Shared secret the website must present. Generated and saved on first run if blank |
store.path | The sidecar's own database. Relative paths resolve beside the config file |
store.retain_days | Days of raw event history the sidecar keeps. 0 keeps everything |
[game].bind stays on loopback. There is no token on the game link — the plugin and the
sidecar share a host, and 127.0.0.1 is the authentication. Moving it to a routable address puts
an unauthenticated command channel for your game server on the network. [web].bind is the one
that may move, behind TLS and a firewall.
[store].retain_days bounds the sidecar’s copy, not the history. The permanent record — per-wipe
totals that survive a wipe — is in the site’s own tables, so shortening it loses recent raw detail
and never a player’s history. Keep the sidecar’s files out of any wipe script’s delete list all
the same: the config holds the token, and the database the recent history.
Environment variables
Section titled “Environment variables”Each overrides one key. An empty variable is ignored, so a panel can declare one and leave it blank without blanking the saved value.
| Variable | Overrides |
|---|---|
RUSTLINK_GAME_BIND | game.bind |
RUSTLINK_SERVER_ID | game.server_id |
RUSTLINK_WEB_BIND | web.bind |
RUSTLINK_WEB_TOKEN | web.auth_token |
RUSTLINK_DB_PATH | store.path |
RUSTLINK_RETAIN_DAYS | store.retain_days |
Both lists are checked against the sidecar’s own source on every build, so a key or a variable added upstream turns this page red rather than quietly going undocumented.
What is not in here
Section titled “What is not in here”- No audience rules. Who may see what is the site’s, on Who sees who is online.
- No site URL. The site reaches the sidecar, never the other way round.
- No protocol version. It is compiled in, because a sidecar that could be configured to claim another protocol would defeat the check.
Canonical documents
Section titled “Canonical documents”sidecar/src/config.rs
is the authority;
rust-link/PROTOCOL.md
§6.2 describes it.