1
0
Fork 0
mirror of https://github.com/kyverno/kyverno.git synced 2025-04-18 02:06:52 +00:00

add value for override of namespace of serviceMonitor ()

* add value for override of namespace of serviceMonitor

Signed-off-by: Issif <issif+github@gadz.org>

* set version of chart to v2.0.1

Signed-off-by: Issif <issif+github@gadz.org>
This commit is contained in:
Thomas Labarussias 2021-08-12 22:14:21 +02:00 committed by GitHub
parent 6ba341ff9b
commit 7c96bd3e21
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 8 additions and 1 deletions

View file

@ -1,6 +1,6 @@
apiVersion: v1
name: kyverno
version: v2.0
version: v2.0.1
appVersion: v1.4.2
icon: https://github.com/kyverno/kyverno/raw/main/img/logo.png
description: Kubernetes Native Policy Management

View file

@ -106,6 +106,7 @@ The following table lists the configurable parameters of the kyverno chart and t
| `service.port` | port for the service | `443` |
| `service.type` | type of service | `ClusterIP` |
| `serviceMonitor.enabled` | create a ServiceMonitor(Requires Prometheus) | `false` |
| `serviceMonitor.namespace` | override namespace for ServiceMonitor (default is same than kyverno) | `false` |
| `serviceMonitor.additionalLabels` | additional labels to add for ServiceMonitor | `nil` |
| `serviceMonitor.interval` | interval to scrape metrics | `30s` |
| `serviceMonitor.scrapeTimeout` | timeout if metrics can't be retrieved in given time interval | `25s` |

View file

@ -13,7 +13,11 @@ metadata:
{{ toYaml .Values.serviceMonitor.additionalLabels | indent 4 }}
{{- end }}
name: {{ template "kyverno.serviceName" . }}-service-monitor
{{- if .Values.serviceMonitor.namespace }}
namespace: {{ .Values.serviceMonitor.namespace }}
{{- else }}
namespace: {{ template "kyverno.namespace" . }}
{{- end }}
spec:
selector:
matchLabels: {{ include "kyverno.matchLabels" . | nindent 6 }}

View file

@ -181,6 +181,8 @@ serviceMonitor:
# Additional labels
additionalLabels:
# key: value
# Override namespace (default is same than kyverno)
namespace:
# Interval to scrape metrics
interval: 30s