From e6029901a2116e4af229f4187c89464d1ee465ed Mon Sep 17 00:00:00 2001 From: "Waylon S. Walker" Date: Tue, 24 Sep 2024 21:21:57 -0500 Subject: [PATCH] keep 3 failures --- temperature-cronjob/templates/cronjob.yaml | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/temperature-cronjob/templates/cronjob.yaml b/temperature-cronjob/templates/cronjob.yaml index 4fdb4b5..586217f 100644 --- a/temperature-cronjob/templates/cronjob.yaml +++ b/temperature-cronjob/templates/cronjob.yaml @@ -5,14 +5,15 @@ metadata: name: {{ .Release.Name }}-cronjob spec: schedule: "{{ .Values.schedule }}" - startingDeadlineSeconds: 200 - concurrencyPolicy: Forbid - successfulJobsHistoryLimit: 1 - failedJobsHistoryLimit: 1 + startingDeadlineSeconds: 200 # Deadline for starting the job + concurrencyPolicy: Forbid # Prevents concurrent runs + successfulJobsHistoryLimit: 3 # Keeps last successful job + failedJobsHistoryLimit: 3 # Keeps last failed job jobTemplate: spec: - activeDeadlineSeconds: 180 - ttlSecondsAfterFinished: 100 + activeDeadlineSeconds: 180 # Limits how long a job can be active + ttlSecondsAfterFinished: 100 # Cleans up finished jobs after 100 seconds + backoffLimit: 3 # Number of retries before considering the job failed template: spec: containers: