Make a proper conf mount for Ushahidi

This commit is contained in:
Disassembler 2018-01-27 14:35:16 +01:00
parent 2584e263fc
commit 045c47a12f
Signed by: Disassembler
GPG Key ID: 524BD33A0EE29499
3 changed files with 4 additions and 4 deletions

View File

@ -13,11 +13,11 @@ export USHAHIDI_PWD=$(head -c 18 /dev/urandom | base64)
envsubst <${SOURCE_DIR}/createdb.sql | docker exec -i mariadb mysql envsubst <${SOURCE_DIR}/createdb.sql | docker exec -i mariadb mysql
# Configure Ushahidi # Configure Ushahidi
mkdir /srv/ushahidi mkdir -p /srv/ushahidi/conf
envsubst <${SOURCE_DIR}/srv/ushahidi/.env >/srv/ushahidi/.env envsubst <${SOURCE_DIR}/srv/ushahidi/conf/env >/srv/ushahidi/conf/env
# Populate database # Populate database
docker run --rm -h ushahidi --link mariadb -v /srv/ushahidi/.env:/srv/ushahidi/platform/.env ushahidi /srv/ushahidi/platform/bin/phinx migrate -c /srv/ushahidi/platform/application/phinx.php docker run --rm -h ushahidi --link mariadb -v /srv/ushahidi/conf/env:/srv/ushahidi/platform/.env ushahidi /srv/ushahidi/platform/bin/phinx migrate -c /srv/ushahidi/platform/application/phinx.php
# Create admin account # Create admin account
export USHAHIDI_ADMIN_USER=admin@example.com export USHAHIDI_ADMIN_USER=admin@example.com

View File

@ -14,7 +14,7 @@ start() {
-h ushahidi \ -h ushahidi \
--link mariadb \ --link mariadb \
-p 127.0.0.1:9014:8014 \ -p 127.0.0.1:9014:8014 \
-v /srv/ushahidi/.env:/srv/ushahidi/platform/.env \ -v /srv/ushahidi/conf/env:/srv/ushahidi/platform/.env \
ushahidi ushahidi
} }