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

15 lines
414 B
Bash
Raw Normal View History

2021-04-27 03:37:04 +02:00
#!/bin/sh
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
sh /setup_msmtp.sh
2021-09-03 21:13:29 +02:00
exec gosu www-data:www-data tini -- php /var/www/html/bin/daemon.php -f start
2021-04-27 03:37:04 +02:00
else
echo "[ERROR] Waited 300 seconds, no response" >&2
fi