From 7bea5cf131a28bc9d5b74f9bc3b6fc4758662026 Mon Sep 17 00:00:00 2001 From: Akash LM Date: Wed, 12 Jun 2024 18:19:13 +0530 Subject: [PATCH] config: add condtion for openebs dashboard --- charts/monitoring/Chart.yaml | 2 +- charts/monitoring/templates/openebs-cstor-dashboard.yaml | 4 +++- charts/monitoring/templates/openebs-cstor-servicemonitor.yaml | 2 ++ charts/monitoring/values.yaml | 4 ++++ 4 files changed, 10 insertions(+), 2 deletions(-) diff --git a/charts/monitoring/Chart.yaml b/charts/monitoring/Chart.yaml index 1da9090b..c6237f05 100644 --- a/charts/monitoring/Chart.yaml +++ b/charts/monitoring/Chart.yaml @@ -8,4 +8,4 @@ dependencies: description: A Helm chart for Monitoring name: monitoring type: application -version: 0.1.22 +version: 0.1.23 diff --git a/charts/monitoring/templates/openebs-cstor-dashboard.yaml b/charts/monitoring/templates/openebs-cstor-dashboard.yaml index afa5112a..f32464c3 100644 --- a/charts/monitoring/templates/openebs-cstor-dashboard.yaml +++ b/charts/monitoring/templates/openebs-cstor-dashboard.yaml @@ -1,3 +1,4 @@ +{{- if .Values.dashboards.openebs }} apiVersion: v1 kind: ConfigMap metadata: @@ -2695,4 +2696,5 @@ data: "uid": "ZzAis83Wz", "version": 11, "weekStart": "" - } \ No newline at end of file + } +{{- end }} \ No newline at end of file diff --git a/charts/monitoring/templates/openebs-cstor-servicemonitor.yaml b/charts/monitoring/templates/openebs-cstor-servicemonitor.yaml index 76d8e037..b6ac2e24 100644 --- a/charts/monitoring/templates/openebs-cstor-servicemonitor.yaml +++ b/charts/monitoring/templates/openebs-cstor-servicemonitor.yaml @@ -1,3 +1,4 @@ +{{- if .Values.dashboards.openebs }} apiVersion: monitoring.coreos.com/v1 kind: ServiceMonitor metadata: @@ -40,3 +41,4 @@ spec: selector: matchLabels: openebs.io/cas-type: cstor +{{- end }} diff --git a/charts/monitoring/values.yaml b/charts/monitoring/values.yaml index 7484ed39..7af3ac79 100644 --- a/charts/monitoring/values.yaml +++ b/charts/monitoring/values.yaml @@ -98,6 +98,9 @@ autoscaling: targetCPUUtilizationPercentage: 80 # targetMemoryUtilizationPercentage: 80 +dashboards: + openebs: true + datasources: prometheus: url: http://prometheus-kube-prometheus-prometheus:9090 @@ -105,6 +108,7 @@ datasources: url: http://prometheus-kube-prometheus-alertmanager:9093 jsonApi: url: http://proact-scheduler.capten.svc.cluster.local:5000/api/v1/schedule/ + nodeSelector: {} tolerations: []