Commit 22037395 authored by Benjamin Rokseth's avatar Benjamin Rokseth
Browse files

Fix entrypoint remote mysql check

parent 2f2b78c5
......@@ -25,6 +25,7 @@ services:
KOHA_ADMINPASS: "${KOHA_ADMINPASS:-secret}"
KOHA_ADMINUSER: "${KOHA_ADMINUSER:-admin}"
KOHA_INSTANCE: "${KOHA_INSTANCE:-name}"
KOHA_DBHOST: localhost
INSTALL_LANGUAGES: "${INSTALL_LANGUAGES}"
DEFAULT_LANGUAGE: "${DEFAULT_LANGUAGE}"
EMAIL_ENABLED: "True"
......
......@@ -14,7 +14,7 @@ echo "Setting up supervisord ..."
envsubst < /templates/global/supervisord.conf.tmpl > /etc/supervisor/conf.d/supervisord.conf
echo "Mysql server setup ..."
if [ -z $KOHA_DBHOST && ping -c 1 -W 1 $KOHA_DBHOST ] ; then
if [[ "$KOHA_DBHOST" != "localhost" && ping -c 1 -W 1 $KOHA_DBHOST ]] ; then
printf "Using linked mysql container $KOHA_DBHOST\n"
else
printf "No linked mysql or unable to connect to linked mysql $KOHA_DBHOST\n-- initializing local mysql ...\n"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment