fix(argo-cd): make ServiceMonitor annotations in ArgoCD server conditional (#2273)

* fix: add argocd servicemonitor annotations conditionally
Signed-off-by: Mats Willemsen <mats.willemsen@ah.nl>

* chore(argo-cd): add changelog

Signed-off-by: Mats Willemsen <mats.willemsen@ah.nl>

---------

Signed-off-by: Mats Willemsen <mats.willemsen@ah.nl>
pull/2275/head argo-cd-5.46.5
Mats Willemsen 2023-09-18 15:21:36 +02:00 committed by GitHub
parent 8d00bec86e
commit 5626d0536f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 5 deletions

View File

@ -3,7 +3,7 @@ appVersion: v2.8.4
kubeVersion: ">=1.23.0-0"
description: A Helm chart for Argo CD, a declarative, GitOps continuous delivery tool for Kubernetes.
name: argo-cd
version: 5.46.4
version: 5.46.5
home: https://github.com/argoproj/argo-helm
icon: https://argo-cd.readthedocs.io/en/stable/assets/logo.png
sources:
@ -27,4 +27,4 @@ annotations:
url: https://argoproj.github.io/argo-helm/pgp_keys.asc
artifacthub.io/changes: |
- kind: fixed
description: Align redis-ha's affinity type to upstream due to warnings
description: fixed issue with argocd-server servicemonitor annotation attribute being added even when no annotations where defined

View File

@ -12,10 +12,10 @@ metadata:
{{- with .Values.server.metrics.serviceMonitor.additionalLabels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.server.metrics.serviceMonitor.annotations }}
annotations:
{{- range $key, $value := .Values.server.metrics.serviceMonitor.annotations }}
{{ $key }}: {{ $value | quote }}
{{- end }}
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
endpoints:
- port: {{ .Values.server.metrics.service.portName }}