DBdock supports three ways to run scheduled backups. Pick based on your deployment.Documentation Index
Fetch the complete documentation index at: https://docs.dbdock.xyz/llms.txt
Use this file to discover all available pages before exploring further.
System cron
Simplest. A crontab entry runs
dbdock backup on a schedule.Programmatic
Long-lived Node.js process using
node-cron.Cloud scheduler
Kubernetes CronJob, AWS EventBridge, GCP Cloud Scheduler.
Option 1 — System cron (recommended for single server)
Add a crontab entry:Pros
- Simplest possible setup
- Battle-tested scheduler
- Works even if DBdock isn’t running
Cons
- Limited logging/observability
- No programmatic control
- Harder on Kubernetes/serverless
Option 2 — Programmatic with node-cron
Run DBdock as a long-lived Node.js process. Useful when you want to share backup scheduling with the rest of your app.Pros
- Full control — custom logic before/after backup
- Tight integration with app observability
- Works with alert programmatic API
Cons
- Needs a long-lived process
- One more thing that can crash
Option 3 — Cloud schedulers
Kubernetes CronJob
AWS EventBridge + Fargate/Lambda
Schedule rule → ECS RunTask (Fargate) that runs a DBdock container. Or package as a Lambda if your backup fits in 15 minutes and 10 GB.GCP Cloud Scheduler + Cloud Run
Cloud Scheduler → HTTPS → Cloud Run service that invokesdbdock backup.
Pros
- Fully managed, scales with your infra
- Rich logging and retry semantics
- Runs even if your app is down
Cons
- More moving pieces
- Infrastructure-specific setup
Using the dbdock schedule command
The dbdock schedule command stores schedules in dbdock.config.json:
dbdock schedule — your scheduler of choice holds the schedule.
Recommended schedule patterns
| Frequency | Cron | Use case |
|---|---|---|
| Every 6 hours | 0 */6 * * * | High-churn production databases |
| Daily at 2 AM | 0 2 * * * | Most production setups |
| Weekly | 0 0 * * 0 | Archival + weekly snapshots |
| Monthly | 0 0 1 * * | Compliance retention |
See also
dbdock schedule
Manage schedules via CLI.
SDK scheduling
Programmatic scheduling details.

