From 0e7c68b7415afe580c360e6691c6e4f05c03bbe6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Bauer?= Date: Tue, 10 Apr 2018 11:17:23 +0200 Subject: [PATCH] Update docker-entrypoint.sh --- containers/zammad/docker-entrypoint.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/containers/zammad/docker-entrypoint.sh b/containers/zammad/docker-entrypoint.sh index c11537f..80557f1 100644 --- a/containers/zammad/docker-entrypoint.sh +++ b/containers/zammad/docker-entrypoint.sh @@ -8,6 +8,7 @@ set -e : "${POSTGRESQL_USER:=postgres}" : "${POSTGRESQL_PASS:=}" : "${POSTGRESQL_DB:=zammad_production}" +: "${POSTGRESQL_DB_CREATE:=true}" : "${ZAMMAD_RAILSSERVER_HOST:=zammad-railsserver}" : "${ZAMMAD_WEBSOCKET_HOST:=zammad-websocket}" : "${NGINX_SERVER_NAME:=_}" @@ -46,7 +47,9 @@ if [ "$1" = 'zammad-init' ]; then set -e if [ "${DB_CHECK}" != "0" ]; then - bundle exec rake db:create + if [ "{POSTGRESQL_DB_CREATE}" == "true" ]; then + bundle exec rake db:create + fi bundle exec rake db:migrate bundle exec rake db:seed fi