From 2fa51525113b7429b79ea064430f7491d88cd97b Mon Sep 17 00:00:00 2001 From: maxmwang Date: Tue, 5 Nov 2024 22:58:05 -0800 Subject: [PATCH] fix cleanup job --- infra/app/templates/cleanup.yaml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/infra/app/templates/cleanup.yaml b/infra/app/templates/cleanup.yaml index c5f85eba3..ea25b4512 100644 --- a/infra/app/templates/cleanup.yaml +++ b/infra/app/templates/cleanup.yaml @@ -11,6 +11,12 @@ spec: containers: - name: cleanup image: alpine/helm - command: ['sh', '-c', 'sleep $(( {{ .Values.ttl }} * 60 * 60 )); helm uninstall {{ .Release.Name }}'] + command: + - sh + - -c + - | + echo "Cleaning up {{ .Release.Name }} in {{ .Values.ttl }} hours" + sleep {{ .Values.ttl }}h + helm uninstall {{ .Release.Name }} restartPolicy: Never {{ end }}