mirror of
https://github.com/onyx-and-iris/q3rcon-proxy.git
synced 2025-05-16 17:10:25 +01:00
upd readme
This commit is contained in:
parent
464fbec85f
commit
43183717f6
34
README.md
34
README.md
@ -8,17 +8,36 @@ Unfortunately the Q3Rcon engine ties the rcon port to the game servers public po
|
|||||||
|
|
||||||
### Use
|
### Use
|
||||||
|
|
||||||
Run one or multiple rcon proxies by setting an environment variable `Q3RCON_TARGET_PORTS`
|
#### Flags
|
||||||
|
|
||||||
for example:
|
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
/usr/local/bin/q3rcon-proxy \
|
||||||
|
--proxy-host=0.0.0.0 \
|
||||||
|
--target-host=localhost \
|
||||||
|
--ports-mapping=28961:28960 \
|
||||||
|
--session-timeout=20 \
|
||||||
|
--loglevel=debug
|
||||||
|
```
|
||||||
|
|
||||||
|
#### Environment Variables
|
||||||
|
|
||||||
|
Each of the flags has a corresponding environment variable:
|
||||||
|
|
||||||
|
- `Q3RCON_PROXY_HOST`: The host the proxy server sits on.
|
||||||
|
- `Q3RCON_TARGET_HOST`: The host the game servers sit on.
|
||||||
|
- `Q3RCON_PORTS_MAPPING`: A mapping as a with `source:target` pairs delimited by `;`.
|
||||||
|
- `Q3RCON_SESSION_TIMEOUT`: Timeout in seconds for each udp session.
|
||||||
|
- `Q3RCON_LOGLEVEL`: The application's logging level (see [Logging][logging]).
|
||||||
|
|
||||||
|
Multiple rcon proxies may be configured by setting *--ports-mapping/Q3RCON_PORTS_MAPPING* like so:
|
||||||
|
|
||||||
|
```console
|
||||||
export Q3RCON_TARGET_PORTS="20000:28960;20001:28961;20002:28962"
|
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.
|
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
|
### Logging
|
||||||
|
|
||||||
@ -47,4 +66,5 @@ If not set it will default to `info`.
|
|||||||
|
|
||||||
For a compatible rcon client also written in Go consider checking out the [Q3 Rcon][q3rcon] package.
|
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
|
[q3rcon]: https://github.com/onyx-and-iris/q3rcon
|
||||||
|
[logging]: https://github.com/onyx-and-iris/gignore?tab=readme-ov-file#logging
|
Loading…
x
Reference in New Issue
Block a user