#!/usr/bin/env sh

set -e

if [ -n "${XDEBUG_MODE}" ]; then
  echo "[xdebug]" > /etc/app/php/95_app_xdebug.ini
  echo "xdebug.mode = ${XDEBUG_MODE}" >> /etc/app/php/95_app_xdebug.ini
fi

echo "Running cron daemon in foreground"
exec /usr/sbin/crond -f -P -s
