feat(argocd-image-updater): Make cm and secret names configurable (#2998)

* feat: made argocd image updater cm and secret name templated

Signed-off-by: AvivGuiser <avivguiser@gmail.com>

* fix indention

Signed-off-by: AvivGuiser <avivguiser@gmail.com>

* update Chart.yaml

Signed-off-by: AvivGuiser <avivguiser@gmail.com>

* chore: Apply changes from code review

Signed-off-by: Marco Maurer <mkilchhofer@users.noreply.github.com>

* chore: Reflect changes from review inside changelog

Signed-off-by: Marco Maurer (-Kilchhofer) <mkilchhofer@users.noreply.github.com>

---------

Signed-off-by: AvivGuiser <avivguiser@gmail.com>
Signed-off-by: Marco Maurer <mkilchhofer@users.noreply.github.com>
Signed-off-by: Marco Maurer (-Kilchhofer) <mkilchhofer@users.noreply.github.com>
Co-authored-by: Marco Maurer <mkilchhofer@users.noreply.github.com>
This commit is contained in:
AvivGuiser 2025-01-25 15:31:37 +02:00 committed by GitHub
parent bf9830c670
commit 79ec8fdb94
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 44 additions and 26 deletions

View file

@ -1,11 +1,17 @@
{{- $sshConfig := omit .Values.config.sshConfig "name" }}
{{- range $key, $val := $sshConfig }}
{{- if not $val }}
{{ $_ := unset $sshConfig $key }}
{{- end }}
{{- end }}
apiVersion: v1
kind: ConfigMap
metadata:
labels:
{{- include "argocd-image-updater.labels" . | nindent 4 }}
name: argocd-image-updater-ssh-config
name: {{ .Values.config.sshConfig.name }}
namespace: {{ include "argocd-image-updater.namespace" . | quote }}
{{- with .Values.config.sshConfig }}
{{- with $sshConfig }}
data:
{{- toYaml . | nindent 2 }}
{{- end }}