https://github.com/openttd/game-coordinator
Game Coordinator, to coordinate network games for OpenTTD
https://github.com/openttd/game-coordinator
Last synced: 11 days ago
JSON representation
Game Coordinator, to coordinate network games for OpenTTD
- Host: GitHub
- URL: https://github.com/openttd/game-coordinator
- Owner: OpenTTD
- License: gpl-2.0
- Created: 2021-07-03T19:08:54.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2025-04-01T22:08:50.000Z (about 2 months ago)
- Last Synced: 2025-04-20T14:42:57.047Z (about 1 month ago)
- Language: Python
- Size: 191 KB
- Stars: 3
- Watchers: 6
- Forks: 2
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Game Coordinator
[](https://github.com/OpenTTD/game-coordinator/blob/main/LICENSE)
This is the Game Coordinator / STUN server to assist in OpenTTD players to play together.
## Development
This server is written in Python 3.11 with aiohttp, and makes strong use of asyncio.
### Running a local server
#### Dependencies
- Python3.11 or higher.
- Redis#### Preparing your venv
To start it, you are advised to first create a virtualenv:
```bash
python3 -m venv .env
.env/bin/pip install -r requirements.txt
```#### Preparing redis
Make sure you have a local redis running. For example via Docker:
```bash
docker run --rm -p 6379:6379 redis
```#### Starting a local server (Game Coordinator)
You can start the Game Coordinator server by running:
```bash
.env/bin/python -m game_coordinator --db redis --app coordinator --shared-secret test --web-port 12345
```#### Starting a local server (STUN Server)
You can start the STUN server by running:
```bash
.env/bin/python -m game_coordinator --db redis --app stun --web-port 12346
```### Running via docker (Game Coordinator)
```bash
docker build -t openttd/game-coordinator:local .
docker run --rm -p 127.0.0.1:3976:3976 openttd/game-coordinator:local
```### Running via docker (STUN server)
```bash
docker build -t openttd/game-coordinator:local .
docker run --rm -p 127.0.0.1:3975:3975 openttd/game-coordinator:local --app stun --bind 0.0.0.0 --db redis --redis-url redis://redis
```