blob: 772add009b788fbe77ecb6924ad5ff015232ce67 [file] [log] [blame]
Nico Huberf4fbab52023-07-25 10:57:08 +00001#!/bin/sh
2
3set -e
4
5{
6 db_secret=/tmp/passwd/db/secret
7
8 i=0
9 while [ -z "$(cat ${db_secret} 2>/dev/null)" ]; do
10 if [ ${i} -eq 10 ]; then
11 echo "ERROR: No password file after ${i}s."
12 exit 1
13 fi
14 sleep 1
15 i=$((i+1))
16 done
17
18 export KC_DB_PASSWORD=$(cat ${db_secret})
19}
20
21exec /opt/keycloak/bin/kc.sh "$@"