2
0
Fork 0
mirror of https://github.com/friendica/docker synced 2024-12-27 15:53:45 +01:00
docker/2024.09-dev/fpm-alpine/cron.sh
2024-08-18 01:48:19 +00:00

14 lines
414 B
Bash
Executable file

#!/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
exec gosu www-data:www-data tini -- php /var/www/html/bin/daemon.php -f start
else
echo "[ERROR] Waited 300 seconds, no response" >&2
fi