Cron jobs
Declare recurring jobs in sextant.yaml with a cron expression, and understand the single-scheduler rule.
Recurring jobs live in the cron section of sextant.yaml. Changing it needs a restart.
sextant.yamlYAML
cron:
- name: nightly-report
schedule: "0 2 * * *"
handler: build-report
payload: { range: 24h }
- name: cleanup
schedule: "*/30 * * * *"
handler: purge-tempExpressions use five fields and are always evaluated in the server’s local time zone. Set TZ=UTC on the process if you want UTC.
One scheduler
Only one process may run the scheduler. v1 elects it with a Redis lock that expires after 30 seconds, so a second sextant start becomes a standby. After a crash, scheduling resumes within 30 seconds.