From 0c8f226f1f8f9d39f5f6dd45fa7a27db67a4413c Mon Sep 17 00:00:00 2001 From: luhahn Date: Thu, 14 Jan 2021 15:13:49 +0800 Subject: [PATCH] Add ldap checksum (#101) Fixed an error in ldap port setting. Added ldap checksum to deployment so chart will actually update on ldap changes. Fixes: #99 Co-authored-by: Lucas Hahn Co-authored-by: Lunny Xiao Reviewed-on: https://gitea.com/gitea/helm-chart/pulls/101 Reviewed-by: lafriks Reviewed-by: Lunny Xiao Co-authored-by: luhahn Co-committed-by: luhahn --- templates/_helpers.tpl | 2 +- templates/gitea/statefulset.yaml | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/templates/_helpers.tpl b/templates/_helpers.tpl index bcbbe24..0cf3021 100644 --- a/templates/_helpers.tpl +++ b/templates/_helpers.tpl @@ -99,7 +99,7 @@ app.kubernetes.io/instance: {{ .Release.Name }} {{- range $key, $val := .Values.gitea.ldap -}} {{- if ne $key "enabled" -}} {{- if eq $key "port" -}} -{{- printf "--%s %s " ($key | kebabcase) $val -}} +{{- printf "--%s %d " ($key | kebabcase) ($val | int) -}} {{- else -}} {{- printf "--%s %s " ($key | kebabcase) ($val | quote) -}} {{- end -}} diff --git a/templates/gitea/statefulset.yaml b/templates/gitea/statefulset.yaml index b1d7a42..bf41b3b 100644 --- a/templates/gitea/statefulset.yaml +++ b/templates/gitea/statefulset.yaml @@ -14,6 +14,7 @@ spec: metadata: annotations: checksum/config: {{ include (print $.Template.BasePath "/gitea/config.yaml") . | sha256sum }} + checksum/ldap: {{ include "gitea.ldap_settings" . | sha256sum }} {{- with .Values.gitea.podAnnotations }} {{- toYaml . | nindent 8 }} {{- end }}