Docker Setup - OpenDAoC
Prerequisites
To run the OpenDAoC Docker container you will need to have Docker and Docker Compose installed on your system.
For instructions on how to install Docker and Docker Compose on your system, please see the Docker documentation.
Docker Compose
OpenDAoC requires a MySQL database to store all persistent data.
The easiest way to get the OpenDAoC image up and running with a paired DB container is to use a docker-compose
file to create the required stack.
We will also use the docker-compose
file to configure the OpenDAoC container with the required environment variables.
A dummy database is provided with the OpenDAoC image that will create the required database and tables when the container is started for the first time.
A more complete and updated database is available on GitHub and can be used to replace the dummy database after the initial setup.
Create a new directory for the OpenDAoC stack and create a docker-compose.yml
file in that directory with the following content:
Launching the server
To start the stack, run the following command in the directory where you created the docker-compose.yml
file:
This will start the OpenDAoC container and the MySQL container in the background.
The first time you start the stack, the MySQL container will create the database and tables required by OpenDAoC. Please be patient as this can take a few minutes.
Updating the database
The docker-compose.yml
file above uses a dummy database to create the required database and tables when the container is started for the first time.
While intended for bootstrapping your server, the dummy database is just a minimal version and does not contain all mobs, items, spells, etc.
Once you have completed the initial setup, you can replace the dummy database with our complete database as covered in the Database section.
Updating the OpenDAoC image
We release updated OpenDAoC images frequently.
It is recommended that you update the OpenDAoC image on a regular basis to ensure that you are running the latest version and are benefiting from the latest bug fixes and features.
To update the OpenDAoC Docker image, you will need to stop the container, pull the latest image and then restart the container.
The steps to do this in a live environment are as follows:
- Issue the
/shutdown
command in-game to stop the server. - Stop the OpenDAoC container once the server has shut down.
- Pull the latest image.
- Start the OpenDAoC container.
The server will now be running the latest version of OpenDAoC.