feat(argo-workflows): argo workflows chart to allow set the namespace of Prometheus ServiceMonitor. (#1104)

* feat(argo-workflows): argo workflows chart to allow set the namespace of Prometheus ServiceMonitor.

Signed-off-by: mugioka <okamugi0722@gmail.com>

* Bump minor chart version

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

Co-authored-by: Marco Kilchhofer <mkilchhofer@users.noreply.github.com>
main argo-workflows-0.10.0
mugi-o 2022-01-28 22:44:46 +09:00 committed by GitHub
parent cf57a71a15
commit 4c1ee93faf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 8 additions and 2 deletions

View File

@ -2,7 +2,7 @@ apiVersion: v2
name: argo-workflows
description: A Helm chart for Argo Workflows
type: application
version: 0.9.5
version: 0.10.0
appVersion: v3.2.6
icon: https://raw.githubusercontent.com/argoproj/argo-workflows/master/docs/assets/argo.png
home: https://github.com/argoproj/argo-helm
@ -15,4 +15,4 @@ maintainers:
- name: benjaminws
annotations:
artifacthub.io/changes: |
- "[Changed]: Consistent .helmignore"
- "[Added]: Add controller serviceMonitor.namespace parameter."

View File

@ -110,6 +110,7 @@ Fields to note:
| controller.serviceLabels | object | `{}` | Optional labels to add to the controller Service |
| controller.serviceMonitor.additionalLabels | object | `{}` | Prometheus ServiceMonitor labels |
| controller.serviceMonitor.enabled | bool | `false` | Enable a prometheus ServiceMonitor |
| controller.serviceMonitor.namespace | string | `""` | Prometheus ServiceMonitor namespace |
| controller.serviceType | string | `"ClusterIP"` | Service type of the controller Service |
| controller.telemetryConfig.enabled | bool | `false` | Enables prometheus telemetry server |
| controller.telemetryConfig.path | string | `"/telemetry"` | telemetry path |

View File

@ -3,6 +3,9 @@ apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
name: {{ template "argo-workflows.controller.fullname" . }}
{{- with .Values.controller.serviceMonitor.namespace }}
namespace: {{ . }}
{{- end }}
labels:
{{- include "argo-workflows.labels" (dict "context" . "component" .Values.controller.name "name" .Values.controller.name) | nindent 4 }}
{{- with .Values.controller.serviceMonitor.additionalLabels }}

View File

@ -145,6 +145,8 @@ controller:
enabled: false
# -- Prometheus ServiceMonitor labels
additionalLabels: {}
# -- Prometheus ServiceMonitor namespace
namespace: "" # "monitoring"
serviceAccount:
# -- Create a service account for the controller
create: true