Why I Built CronGuard (And Why You Need It)
From a late-night database incident to a live SaaS product: how one failing cron job led to CronGuard, and what I learned while building it.
Jean-Pierre Broeders
Freelance DevOps Engineer
Why I Built CronGuard (And Why You Need It)
It was 3 AM when my phone rang. A client. Panic in his voice. "Yesterday's database backup is corrupted. We need the one from two days ago, but that's missing too. What happened?"
What happened? A cron job had silently failed. No error logs. No alerts. Just... stopped.
The Problem I Kept Running Into
As a freelance DevOps engineer, I see this pattern constantly:
- Team sets up a cron job for something critical (backups, invoices, data sync)
- Job runs fine... for a while
- Something goes wrong somewhere (disk full, API down, dependencies update)
- Nobody notices
- Days later: crisis
The worst part? It was always preventable.
The truth is that cron jobs are the silent heroes of your infrastructure — until they become the silent killers.
Why Existing Tools Didn't Work
I tried different solutions:
Dead Man's Switch services — too basic. They only check "did it run?", not "did it succeed?"
Full monitoring stacks (Prometheus, Grafana, Datadog) — overkill. I don't want to set up an entire observability platform to monitor 5 cron jobs.
Custom scripts — work... until you have to maintain them. And debug them. And document them. And share them with your team.
What I needed was simple:
- Know when a job should run
- Check if it actually ran
- Alert me if it fails
- Make debugging easy
The Birth of CronGuard
I built CronGuard in a weekend. Well, the MVP. The first version could:
- Unique URL per job — curl that URL at the end of your script
- Grace periods — if the job doesn't check in within X minutes, alarm
- Email alerts — simple, effective
- Dashboard — overview of all jobs at a glance
Example usage:
#!/bin/bash
# Your normal cron job
pg_dump mydb > backup.sql
# Check in with CronGuard
curl -X POST https://cronguard.app/ping/abc123xyz
That simple. Always works.
What I Learned While Building
1. Exit Codes Aren't Enough
Many monitoring tools only check the exit code. But a script can return exit 0 while actually failing:
#!/bin/bash
# This always returns exit 0, even if backup fails
pg_dump mydb > backup.sql
echo "Backup completed" # exit 0
CronGuard's solution: Check not just if the script ran, but if it checked in on time. If your script crashes before the curl, you get an alert.
2. Grace Periods Are Critical
Not all jobs take the same time. A 10GB backup takes longer than a 1GB one. With fixed timeouts, you get false positives.
CronGuard's solution: Set a grace period per job. The job can vary within that window before being marked as "too late."
3. Debugging Must Be Easy
When a job fails at 3 AM, you don't want to dig through logs. You want to see:
- When did it last run?
- What was the output?
- How many times has it failed?
CronGuard's solution: Each ping can include a status message:
curl -X POST https://cronguard.app/ping/abc123xyz \
-d "Backup completed: 10.2GB, 47 tables"
All in the dashboard. Logs without the complexity.
4. Integrations Are Essential
Email alerts are fine, but if your team works in Slack, you want to see the alert there.
CronGuard supports:
- Slack
- Discord
- Webhooks (for custom integrations)
- SMS (for critical jobs)
Real-World Use Cases
After a few months live, I see CronGuard being used for:
Scheduled backups — the original use case. Database dumps, file backups, replication jobs.
Invoice generation — e-commerce sites generating and sending invoices every night.
Data synchronization — syncing between CRM, ERP, and other business tools.
Report generation — weekly/monthly reports that need to go to management.
Cleanup jobs — removing old logs, clearing cache, cleaning up temp files.
Health checks — periodic checks to see if external APIs are still alive.
The Tech Stack (For The Nerds)
CronGuard runs on:
- Next.js 15 (app router) for frontend + API routes
- Neon (serverless Postgres) for data storage
- Clerk for authentication
- Vercel for hosting
- Resend for email delivery
Why this stack?
- Serverless = no maintenance — I don't want to manage servers
- Edge-ready — fast response times worldwide
- Developer experience — building should be fun, not painful
- Scalable — from 10 jobs to 10,000 without infrastructure changes
What It Costs (And Why)
I wanted to make CronGuard accessible, not another expensive enterprise tool.
Free tier:
- Up to 5 jobs
- Email alerts
- 30 days history
- Basic dashboard
Pro tier ($9/month):
- Unlimited jobs
- All notification channels
- 1 year history
- Advanced analytics
- Priority support
No surprises. No per-ping pricing. Just simple.
Lessons Learned About Building SaaS
This was my first real SaaS product. What I learned:
Start Small, Ship Fast
The first version had no fancy analytics, no team features, no API. Just: ping a URL, get alerts. That was enough to deliver value.
Features came later, based on what users actually asked for.
Documentation Is Marketing
Good docs = fewer support tickets + better conversion. I wrote guides for:
- Every popular cron scheduler
- Common use cases
- Integration examples
Developers read docs. Make them good.
Monitoring Your Monitoring Tool Is Meta
The irony: CronGuard itself runs cron jobs (alerts, cleanup, analytics). So I use... CronGuard to monitor CronGuard. It works surprisingly well.
Why You Should Try CronGuard
If you run cron jobs that matter (and which ones don't?), you need monitoring.
You can:
- Build a custom solution (cost: 10-20 hours + maintenance)
- Buy an enterprise monitoring stack (cost: $100-500/month)
- Use CronGuard (cost: free to $9/month)
I built CronGuard because I wanted option 3. No overkill, no underkill. Just right.
Try it free: cronguard.app
Setup literally takes 2 minutes. Add one curl to your script, and you're done.
What's Next?
I'm working on:
- Retry logic — automatic retry on transient failures
- Team features — shared dashboards, role-based access
- Terraform/Pulumi provider — infrastructure as code integration
- Status pages — public status page for your jobs
Have feature requests? Suggestions? Let me know.
CronGuard is live at cronguard.app. Free tier, no credit card required. Setup in 2 minutes.
