Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix wrong namespaceSelector in servicemonitor #127

Merged
merged 1 commit into from
Aug 8, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions charts/coredns/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
apiVersion: v2
name: coredns
version: 1.24.3
version: 1.24.4
appVersion: 1.10.1
home: https://coredns.io
icon: https://coredns.io/images/CoreDNS_Colour_Horizontal.png
Expand All @@ -19,5 +19,5 @@ engine: gotpl
type: application
annotations:
artifacthub.io/changes: |
- kind: Added
description: Added a job to the github action for repo addition.
- kind: fixed
description: Fix wrong namespaceSelector in ServiceMonitor when using custom monitoring namespace
5 changes: 5 additions & 0 deletions charts/coredns/templates/servicemonitor.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@ metadata:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
{{- if ne .Values.prometheus.monitor.namespace .Release.Namespace }}
namespaceSelector:
matchNames:
- {{ .Release.Namespace }}
{{- end }}
selector:
matchLabels:
app.kubernetes.io/instance: {{ .Release.Name | quote }}
Expand Down
Loading