Kubernetes CronJob — Schedule Pods on a Timer
*/5 * * * *Every 5 minutes
Next 10 Executions
Times shown in UTC
- Mon, May 18, 202608:10
- Mon, May 18, 202608:15
- Mon, May 18, 202608:20
- Mon, May 18, 202608:25
- Mon, May 18, 202608:30
- Mon, May 18, 202608:35
- Mon, May 18, 202608:40
- Mon, May 18, 202608:45
- Mon, May 18, 202608:50
- Mon, May 18, 202608:55
Field Breakdown
*/5Minute
Every 5 minutes
*Hour
Every hour
*Day of Month
Every day
*Month
Every month
*Day of Week
Every day of week
About This Schedule
Kubernetes CronJobs use standard 5-field cron syntax to schedule Jobs on a recurring basis:
apiVersion: batch/v1
kind: CronJob
metadata:
name: my-cronjob
spec:
schedule: "*/5 * * * *"
jobTemplate:
spec:
template:
spec:
containers:
- name: my-job
image: my-image:latest
restartPolicy: OnFailureKey points about Kubernetes CronJobs:
- Standard syntax: 5 fields, same as Unix cron
- Timezone: Defaults to kube-controller-manager timezone (usually UTC). Since Kubernetes 1.27, you can set
timeZonefield - Concurrency: Control with
concurrencyPolicy: Allow, Forbid, or Replace - History: Configure
successfulJobsHistoryLimitandfailedJobsHistoryLimit - Deadline: Set
startingDeadlineSecondsto handle missed schedules