Optimised multi layered builds to speed up deployment, added comments to help new developers, reduced unnecessary objects being sent to the docker build context, mounted in files that may change regularly to remove the requirement for a full rebuild.

This commit is contained in:
James McDowell
2021-05-16 09:59:12 +10:00
parent d98ab8cf1e
commit 8429d78e01
3 changed files with 52 additions and 14 deletions

View File

@@ -5,8 +5,18 @@ services:
depends_on:
- db
ports:
# Login server
- "8484:8484"
# Channels.
# Format: WWCC, where WW is 75 plus the world number and CC is 75 plus the channel number (both zero indexed).
# In this case, world 1 channels 1-3.
- "7575-7577:7575-7577"
volumes:
# Config changes can be reloaded without rebuilding the image.
# Still requires a redeployment as they're sourced on startup.
- ./config.yaml:/opt/server/config.yaml
- ./scripts:/opt/server/scripts
- ./wz:/opt/server/wz
environment:
DB_HOST: "db"