mirror of
https://github.com/onyx-and-iris/q3rcon-proxy.git
synced 2025-04-09 15:23:45 +01:00
50 lines
1.4 KiB
Markdown
50 lines
1.4 KiB
Markdown
# Q3 Rcon Proxy
|
|
|
|
A modification of [lilproxy][lilproxy_url] that forwards only Q3 rcon/query packets. Useful for separating the rcon port from the game server port.
|
|
|
|
### Why
|
|
|
|
Unfortunately the Q3Rcon engine ties the rcon port to the game servers public port used for client connections. This proxy will allow you to run rcon through a separate whitelisted port.
|
|
|
|
### Use
|
|
|
|
Run one or multiple rcon proxies by setting an environment variable `Q3RCON_TARGET_PORTS`
|
|
|
|
for example:
|
|
|
|
```bash
|
|
export Q3RCON_TARGET_PORTS="20000:28960;20001:28961;20002:28962"
|
|
```
|
|
|
|
This would configure q3rcon-proxy to run 3 proxy servers listening on ports `20000`, `20001` and `20002` that redirect rcon requests to game servers on ports `28960`, `28961` and `28962` respectively.
|
|
|
|
Then just run the binary which you can compile yourself, download from `Releases` or use the included Dockerfile.
|
|
|
|
### Logging
|
|
|
|
Set the log level with environment variable `Q3RCON_LOGLEVEL`.
|
|
|
|
Acceptable values are:
|
|
|
|
- `trace`
|
|
- `debug`
|
|
- `info`
|
|
- `warn`
|
|
- `error`
|
|
- `fatal`
|
|
- `panic`
|
|
|
|
If not set it will default to `info`.
|
|
|
|
### Special Thanks
|
|
|
|
[Dylan][user_link] For writing [lilproxy][lilproxy_url].
|
|
|
|
[lilproxy_url]: https://github.com/dgparker/lilproxy
|
|
[user_link]: https://github.com/dgparker
|
|
|
|
### Further Notes
|
|
|
|
For a compatible rcon client also written in Go consider checking out the [Q3 Rcon][q3rcon] package.
|
|
|
|
[q3rcon]: https://github.com/onyx-and-iris/q3rcon |