From 2c5433d1417f1c838e89a6f4553e91cde23dbaff Mon Sep 17 00:00:00 2001 From: Todd Brown Date: Thu, 16 May 2019 15:04:32 -0500 Subject: [PATCH] [stable/traefik] cleanup storeconfig-job hook (#12188) Adding helm hook delete policy so hook is deleted if successful or if running install again after a failure. Signed-off-by: Todd Brown --- stable/traefik/Chart.yaml | 2 +- stable/traefik/templates/storeconfig-job.yaml | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/stable/traefik/Chart.yaml b/stable/traefik/Chart.yaml index 1ba60be356..e567500191 100644 --- a/stable/traefik/Chart.yaml +++ b/stable/traefik/Chart.yaml @@ -1,6 +1,6 @@ apiVersion: v1 name: traefik -version: 1.68.2 +version: 1.68.3 appVersion: 1.7.9 description: A Traefik based Kubernetes ingress controller with Let's Encrypt support keywords: diff --git a/stable/traefik/templates/storeconfig-job.yaml b/stable/traefik/templates/storeconfig-job.yaml index 90bad90a48..14d3d068c7 100644 --- a/stable/traefik/templates/storeconfig-job.yaml +++ b/stable/traefik/templates/storeconfig-job.yaml @@ -5,19 +5,20 @@ metadata: name: "storeconfig-job-{{ .Release.Revision }}" annotations: "helm.sh/hook": post-install,post-upgrade + "helm.sh/hook-delete-policy": "hook-succeeded,before-hook-creation" labels: chart: {{ template "traefik.chart" . }} app: {{ template "traefik.name" . }} spec: template: - metadata: + metadata: name: "storeconfig-job-{{ .Release.Revision }}" labels: app: {{ template "traefik.name" . }} chart: {{ template "traefik.chart" . }} spec: restartPolicy: Never - containers: + containers: - name: storeconfig-job image: "{{ .Values.image }}:{{ .Values.imageTag }}" args: