Thanks to visit codestin.com
Credit goes to github.com

Skip to content

TrueBrain/OpenTTD-game-coordinator

 
 

Repository files navigation

Game Coordinator

GitHub License GitHub Tag GitHub commits since latest release

GitHub Workflow Status (Testing) GitHub Workflow Status (Publish Image) GitHub Workflow Status (Deployments)

GitHub deployments (Staging) GitHub deployments (Production)

This is the Game Coordinator / STUN server to assist in OpenTTD players to play together.

Development

This server is written in Python 3.8 with aiohttp, and makes strong use of asyncio.

Running a local server

Dependencies

  • Python3.8 or higher.
  • Redis

Preparing your venv

To start it, you are advised to first create a virtualenv:

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:

docker run --rm -p 6379:6379 redis

Starting a local server (Game Coordinator)

You can start the Game Coordinator server by running:

.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:

.env/bin/python -m game_coordinator --db redis --app stun --web-port 12346

Running via docker (Game Coordinator)

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)

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

About

Game Coordinator, to coordinate network games for OpenTTD

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Languages

  • Python 98.0%
  • Dockerfile 2.0%