You've already forked hotpocket
This commit is contained in:
18
services/base/ops/bin/wait-for-cloud.sh
Executable file
18
services/base/ops/bin/wait-for-cloud.sh
Executable file
@@ -0,0 +1,18 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [ -x "$(command -v 'wait-for-it')" ];then
|
||||
if [ ! -z "${POSTGRES_HOSTPORT}" ];then
|
||||
echo "Waiting for postgres at ${POSTGRES_HOSTPORT}..."
|
||||
wait-for-it -t 60 "${POSTGRES_HOSTPORT}" && echo "postgres is up"
|
||||
fi
|
||||
|
||||
if [ ! -z "${RABBITMQ_HOSTPORT}" ];then
|
||||
echo "Waiting for rabbitmq at ${RABBITMQ_HOSTPORT}..."
|
||||
wait-for-it -t 60 "${RABBITMQ_HOSTPORT}" && echo "rabbitmq is up"
|
||||
fi
|
||||
|
||||
if [ ! -z "${KEYCLOAK_HOSTPORT}" ];then
|
||||
echo "Waiting for keycloak at ${KEYCLOAK_HOSTPORT}..."
|
||||
wait-for-it -t 60 "${KEYCLOAK_HOSTPORT}" && echo "keycloak is up"
|
||||
fi
|
||||
fi
|
||||
Reference in New Issue
Block a user