From 8938b35e3b1d79bed79ad1f135afa1c05c3757f3 Mon Sep 17 00:00:00 2001 From: matthew-fuller Date: Sat, 1 Jun 2019 00:00:06 -0700 Subject: [PATCH] Exposed backoffLimit and restartPolicy in chart values This change allows the restartPolicy of the tempest test pod to be set to Never, bringing it in line with other test pod behavior, like rally. If set to OnFailure, test pods are often deleted before logs can be viewed. Change-Id: I312b93784d27109452b2076658e5655210a92b48 --- tempest/templates/job-run-tests.yaml | 3 ++- tempest/values.yaml | 5 +++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/tempest/templates/job-run-tests.yaml b/tempest/templates/job-run-tests.yaml index f2ed054d7a..b63dd1c1d6 100644 --- a/tempest/templates/job-run-tests.yaml +++ b/tempest/templates/job-run-tests.yaml @@ -28,13 +28,14 @@ metadata: annotations: {{ tuple $envAll | include "helm-toolkit.snippets.release_uuid" }} spec: + backoffLimit: {{ .Values.jobs.run_tests.backoffLimit }} template: metadata: labels: {{ tuple $envAll "tempest" "run-tests" | include "helm-toolkit.snippets.kubernetes_metadata_labels" | indent 8 }} spec: serviceAccountName: {{ $serviceAccountName }} - restartPolicy: OnFailure + restartPolicy: {{ .Values.jobs.run_tests.restartPolicy }} nodeSelector: {{ .Values.labels.job.node_selector_key }}: {{ .Values.labels.job.node_selector_value }} initContainers: diff --git a/tempest/values.yaml b/tempest/values.yaml index fba3b83d80..fdaa27a060 100644 --- a/tempest/values.yaml +++ b/tempest/values.yaml @@ -35,6 +35,11 @@ images: - dep_check - image_repo_sync +jobs: + run_tests: + backoffLimit: 6 + restartPolicy: OnFailure + pod: user: tempest: