From 47323a2625f08430eeaa5d2f51852c8dfa600209 Mon Sep 17 00:00:00 2001 From: David Markowitz Date: Mon, 9 Dec 2024 23:30:54 -0800 Subject: [PATCH] add env vars with defaults for docker --- .env.example | 9 +++++++++ docker-compose.yml | 4 ++++ 2 files changed, 13 insertions(+) diff --git a/.env.example b/.env.example index 5e84184c0..97dd3defd 100644 --- a/.env.example +++ b/.env.example @@ -7,8 +7,17 @@ NET_VERSION=171022 ACCOUNT_MANAGER_SECRET= # Should be the externally facing IP of your server host EXTERNAL_IP=localhost + + +# If using sqlite, set this to 1 and the others to 0. You can ignore the mariadb values if you are using sqlite. +USING_SQLITE=1 +SQLITE_DATABASE_PATH=resServer/dlu.sqlite + +# If using mysql, set this to 1 and the others to 0. You can ignore the sqlite values if you are using mysql. +USING_MYSQL=0 # Database values # Be careful with special characters here. It is more safe to use normal characters and/or numbers. MARIADB_USER=darkflame MARIADB_PASSWORD= MARIADB_DATABASE=darkflame +SKIP_ACCOUNT_CREATION=1 diff --git a/docker-compose.yml b/docker-compose.yml index 8f5a3d09c..1732e4238 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -34,6 +34,10 @@ services: - CLIENT_LOCATION=/app/luclient - DLU_CONFIG_DIR=/app/configs - DUMP_FOLDER=/app/dump + - USING_SQLITE=${USING_SQLITE:-1} + - SQLITE_DATABASE_PATH=${SQLITE_DATABASE_PATH:-resServer/dlu.sqlite} + - USING_MYSQL=${USING_MYSQL:-0} + - SKIP_ACCOUNT_CREATION=${SKIP_ACCOUNT_CREATION:-1} - MYSQL_HOST=darkflamedb - MYSQL_DATABASE=${MARIADB_DATABASE:-darkflame} - MYSQL_USERNAME=${MARIADB_USER:-darkflame}