busybox-cronjob.yaml 443 B

12345678910111213141516171819202122
  1. apiVersion: batch/v1beta1
  2. kind: CronJob
  3. metadata:
  4. name: cronjob-test
  5. spec:
  6. schedule: "*/1 * * * *"
  7. concurrencyPolicy: Allow
  8. suspend: false
  9. startingDeadlineSeconds: 30
  10. successfulJobsHistoryLimit: 3
  11. failedJobsHistoryLimit: 1
  12. jobTemplate:
  13. spec:
  14. template:
  15. spec:
  16. containers:
  17. - name: test
  18. image: busybox
  19. args:
  20. - "/bin/true"
  21. restartPolicy: OnFailure