From e3e4a91dcd5d7e68861fa14889fde22bd2ada08b Mon Sep 17 00:00:00 2001 From: Disassembler Date: Sat, 27 Jan 2018 14:27:28 +0100 Subject: [PATCH] Make a proper conf mount for OpenMapKit --- openmapkit.sh | 4 ++-- openmapkit/etc/init.d/openmapkit | 2 +- openmapkit/srv/openmapkit/{ => conf}/settings.js | 0 3 files changed, 3 insertions(+), 3 deletions(-) rename openmapkit/srv/openmapkit/{ => conf}/settings.js (100%) diff --git a/openmapkit.sh b/openmapkit.sh index 3bc6e28..b969084 100755 --- a/openmapkit.sh +++ b/openmapkit.sh @@ -8,9 +8,9 @@ docker build -t openmapkit ${SOURCE_DIR} # Configure OpenMapKit export OMK_ADMIN_USER="admin" export OMK_ADMIN_PWD=$(head -c 12 /dev/urandom | base64) -mkdir -p /srv/openmapkit/data/deployments /srv/openmapkit/data/submissions -envsubst <${SOURCE_DIR}/srv/openmapkit/settings.js >/srv/openmapkit/settings.js +mkdir -p /srv/openmapkit/conf /srv/openmapkit/data/deployments /srv/openmapkit/data/submissions chown -R 8007:8007 /srv/openmapkit/data +envsubst <${SOURCE_DIR}/srv/openmapkit/conf/settings.js >/srv/openmapkit/conf/settings.js # Configure OpenMapKit service cp ${SOURCE_DIR}/etc/init.d/openmapkit /etc/init.d/openmapkit diff --git a/openmapkit/etc/init.d/openmapkit b/openmapkit/etc/init.d/openmapkit index 1e2b662..3a951b1 100755 --- a/openmapkit/etc/init.d/openmapkit +++ b/openmapkit/etc/init.d/openmapkit @@ -12,7 +12,7 @@ start() { --name openmapkit \ -h openmapkit \ -p 127.0.0.1:9007:8007 \ - -v /srv/openmapkit/settings.js:/srv/openmapkit/settings.js \ + -v /srv/openmapkit/conf/settings.js:/srv/openmapkit/settings.js \ -v /srv/openmapkit/data:/srv/openmapkit/data \ openmapkit } diff --git a/openmapkit/srv/openmapkit/settings.js b/openmapkit/srv/openmapkit/conf/settings.js similarity index 100% rename from openmapkit/srv/openmapkit/settings.js rename to openmapkit/srv/openmapkit/conf/settings.js