diff --git a/docker-entrypoint.sh b/docker-entrypoint.sh index 7bc2b51..71b227a 100755 --- a/docker-entrypoint.sh +++ b/docker-entrypoint.sh @@ -9,6 +9,15 @@ fi if [ "$1" = 'bin/catalina.sh' ]; then + echo + echo '**************************************' + echo "Waiting for Postgress to start " + echo '**************************************' + echo + while ! nc -z "${DB_HOST:-db}" "${DB_PORT:-5432}"; do + sleep 0.1 + done + METACAT_DEFAULT_WAR=/usr/local/tomcat/webapps/metacat.war METACAT_DIR=/usr/local/tomcat/webapps/${METACAT_APP_CONTEXT}