Use a single frequently-running Render cron with time checks in the shell script instead of multiple dedicated cron services
Instead of creating a separate Render cron service for each scheduled task (each with its own build step, env vars, secret group attachments, and billing), consolidate into a single frequently-running cron service that dispatches based on the current time.
Pattern:
# Single cron service running every 10 minutes (*/10 * * * *)
set -o errexit
# Always-run tasks
python -m myapp do-frequent-thing
# Time-gated tasks
HOUR=$(date -u +%H)
MINUTE=$(date -u +%M)
if [ "$HOUR" = "10" ] && [ "$MINUTE" = "30" ]; then
python -m myapp do-morning-thing
fi
if [ "$HOUR" = "21" ] && [ "$MINUTE" = "00" ]; then
python -m myapp do-evening-thing
fiRequirements:
*/10 hits :00, :10, :20, :30, :40, :50 — so 10:30 and 21:00 both hit exactly)Benefits: