# CareBill — cron. Install for the web server user: # crontab -u www-data deploy/crontab.txt # # Both jobs take a database lock, so an overrun that overlaps the next run is # safe: the second one stands aside and the ladder catches up the following night. # nightly: bill what is due, chase what is overdue, renewals, revenue, TDS, integrity, backup 30 6 * * * cd /var/www/carebill && php cron/daily.php >> storage/logs/cron.log 2>&1 # every five minutes: send queued mail and WhatsApp inside the sending window */5 * * * * cd /var/www/carebill && php cron/queue.php >> storage/logs/cron.log 2>&1 # weekly: prove the live server is still healthy; the output lands in the log 0 7 * * 1 cd /var/www/carebill && php tools/smoke_test.php >> storage/logs/smoke.log 2>&1