Docker
Summary
These instructions will allow you run tbaMUD inside of a Docker container on your computer (any OS) with no manual configuration or additional software installation necessary.
- It will setup a Ubuntu 18.04 container running the game over port 4000.
- Any changes to your game code will require you to rebuild & restart the container.
- Could improvements be made? Sure.
- Could this be a bit cleaner or more efficient? You betcha.
- I just wanted to get this out there so that it'd be even easier for folks who would like to see the game running, to be able to.
Requirements
install Docker & docker-compose for whatever platform you wish to run as the game server.
Setup
- edit the files to your liking
- add Dockerfile & docker-compose.yaml to the base directory of the project (folder with /src).
Files
Dockerfile
docker-compose.yaml
Use
Startup
- on CLI, change to base directory
- docker-compose up -d
- this will build the server image that the container will run, with all the dependencies needed to compile & run tbaMUD
- then it will start the gameserver container
Shutdown
- on CLI, change to base directory
- docker-compose down
- this will stop the game server container
Troubleshooting
- ERR: I honestly do not see how this any error could occur if you have Docker running on your machine, except maybe a port conflict.
- Cause: is it plugged in?
- Remediation: plug it in.
References