Init DB JDBC URI from base DB params

Signed-off-by: mathieu.brunot <mathieu.brunot@monogramm.io>
This commit is contained in:
mathieu.brunot 2019-07-19 14:36:23 +02:00 committed by Andrey Antukh
parent d17db88088
commit 9c61389830
2 changed files with 7 additions and 0 deletions

View file

@ -4,5 +4,11 @@ set -e
echo "Synchronize static data..."
rsync -avr --delete ./resources/public/static/ ./data/static/
if [ -z "$UXBOX_DATABASE_URI" ]; then
echo "Initializing database connection string..."
UXBOX_DATABASE_URI="\"jdbc:postgresql://$(echo ${UXBOX_DATABASE_SERVER} | tr -d '"'):${UXBOX_DATABASE_PORT}/$(echo ${UXBOX_DATABASE_NAME} | tr -d '"')\""
echo "Database connection string: $UXBOX_DATABASE_URI"
fi
echo "Setting up UXBOX Backend..."
exec "$@"