From ea426ca0f408b09cb054e3f4109e81d83a1a3d26 Mon Sep 17 00:00:00 2001 From: Alex Muthmann Date: Tue, 5 Mar 2019 14:05:49 +0100 Subject: [PATCH] Update README.md --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 3786fb4..4c3908d 100644 --- a/README.md +++ b/README.md @@ -182,7 +182,7 @@ Create file `config/server-adminlist.json` and add the adminlisted users. "friend" ] -## Customize configuration files +## Customize configuration files (0.17.x+) Out-of-the box, factorio does not support environment variables inside the configuration files. A workaround is the usage of `envsubst` which generates the configuration files dynamically during startup from environment variables set in docker-compose: @@ -199,7 +199,7 @@ Example which replaces the server-settings.json: environment: - INSTANCE_NAME=Your Instance's Name - INSTANCE_DESC=Your Instance's Description - entrypoint: /bin/sh -c "envsubst < /server-settings.json > /factorio/config/server-settings.json && exec /docker-entrypoint.sh" + entrypoint: /bin/sh -c "mkdir -p /factorio/config && envsubst < /server-settings.json > /factorio/config/server-settings.json && exec /docker-entrypoint.sh" The `server-settings.json` file may then contain the variable references like this: