diff --git a/charts/nextcloud/Chart.yaml b/charts/nextcloud/Chart.yaml index 8981918f..bb5a2f67 100644 --- a/charts/nextcloud/Chart.yaml +++ b/charts/nextcloud/Chart.yaml @@ -1,6 +1,6 @@ apiVersion: v2 name: nextcloud -version: 4.5.18 +version: 4.5.19 appVersion: 28.0.2 description: A file sharing server that puts the control and security of your own data back into your hands. keywords: diff --git a/charts/nextcloud/templates/metrics/servicemonitor.yaml b/charts/nextcloud/templates/metrics/servicemonitor.yaml index 116721b0..b84196a0 100644 --- a/charts/nextcloud/templates/metrics/servicemonitor.yaml +++ b/charts/nextcloud/templates/metrics/servicemonitor.yaml @@ -21,8 +21,12 @@ spec: app.kubernetes.io/instance: {{ .Release.Name }} app.kubernetes.io/component: metrics namespaceSelector: + {{- with .Values.metrics.serviceMonitor.namespaceSelector }} + {{- toYaml . | nindent 4 }} + {{- else }} matchNames: - {{ .Release.Namespace | quote }} + {{- end }} endpoints: - port: metrics path: "/" diff --git a/charts/nextcloud/values.yaml b/charts/nextcloud/values.yaml index 0d2d9368..f740c368 100644 --- a/charts/nextcloud/values.yaml +++ b/charts/nextcloud/values.yaml @@ -517,6 +517,9 @@ metrics: ## namespace: "" + ## @param metrics.serviceMonitor.namespaceSelector The selector of the namespace where the target service is located (defaults to the release namespace) + namespaceSelector: + ## @param metrics.serviceMonitor.jobLabel The name of the label on the target service to use as the job name in prometheus. ## jobLabel: ""