2
0
Fork 0
mirror of https://github.com/friendica/docker synced 2024-11-15 18:59:27 +01:00
docker/docker-cron.sh

14 lines
378 B
Bash
Raw Normal View History

#!/bin/sh
2018-05-22 21:47:37 +02:00
trap "break;exit" HUP INT TERM
while [ ! -f /var/www/html/bin/daemon.php ]; do
sleep 1
done
echo "Waiting for MySQL $MYSQL_HOST initialization..."
if php /var/www/html/bin/wait-for-connection "$MYSQL_HOST" "${MYSQL_PORT:-3306}" 300; then
2020-03-08 20:47:56 +01:00
exec /sbin/tini -- php /var/www/html/bin/daemon.php -f start
2019-12-31 01:53:22 +01:00
else
echo "[ERROR] Waited 300 seconds, no response" >&2
fi