diff --git a/.env.sample b/.env.sample
index e5f8548..68fa565 100644
--- a/.env.sample
+++ b/.env.sample
@@ -3,11 +3,16 @@ DATABASE_PORT=5432
REDIS_PORT=6379
ADMINER_PORT=8080
DATA_FOLDER=./data
-
-# Change this to your local game folder
GAME_FOLDER=/res
# Postgres specific setup
POSTGRES_USER=uchu
POSTGRES_PASSWORD=uchu
-POSTGRES_DB=uchu
\ No newline at end of file
+POSTGRES_DB=uchu
+
+# Uchu specific setup
+CHARACTER_PORT=2002
+API_PORT=10000
+MAX_WORLD_SERVERS=100
+# Should be API_PORT + MAX_WORLD_SERVERS
+MAX_API_PORT=10100
\ No newline at end of file
diff --git a/Uchu.Dockerfile b/Uchu.Dockerfile
index fbbdf63..625afb2 100644
--- a/Uchu.Dockerfile
+++ b/Uchu.Dockerfile
@@ -3,6 +3,7 @@ COPY Uchu config.default.xml .env ./
RUN apk add gettext
RUN set -o allexport && source .env && set +o allexport && envsubst < config.default.xml > config.xml
+RUN cat config.xml
RUN dotnet build
ENTRYPOINT ["dotnet", "Uchu.Master/bin/Debug/netcoreapp3.1/Uchu.Master.dll"]
\ No newline at end of file
diff --git a/config.default.xml b/config.default.xml
index f810d98..b1d3ae7 100644
--- a/config.default.xml
+++ b/config.default.xml
@@ -28,10 +28,10 @@
- 2002
+ $CHARACTER_PORT
true
true
- 100
+ $MAX_WORLD_SERVERS
false
@@ -40,7 +40,7 @@
http
localhost
- 10000
+ $API_PORT
diff --git a/docker-compose.yaml b/docker-compose.yaml
index bc4c292..2f8785b 100644
--- a/docker-compose.yaml
+++ b/docker-compose.yaml
@@ -5,7 +5,8 @@ services:
env_file:
- .env
restart: always
- ports: ["${DATABASE_PORT}:5432"]
+ ports:
+ - "${DATABASE_PORT}:5432"
volumes:
- ${DATA_FOLDER}:/var/lib/postgresql/data
adminer:
@@ -13,13 +14,15 @@ services:
restart: always
depends_on:
- db
- ports: ["${ADMINER_PORT}:8080"]
+ ports:
+ - "${ADMINER_PORT}:8080"
redis:
image: redis:6.0.8-alpine
env_file:
- .env
restart: always
- ports: ["${REDIS_PORT}:6379"]
+ ports:
+ - "${REDIS_PORT}:6379"
volumes:
- ${DATA_FOLDER}:/data
uchu:
@@ -33,5 +36,8 @@ services:
- .env
volumes:
- ${GAME_FOLDER}:/res
+ ports:
+ - "2002:${CHARACTER_PORT}"
+ - "10000-10100:${API_PORT}-${MAX_API_PORT}"
tty: true
stdin_open: true