From 27ed2368da4827a13cabca5db5fed4af07da8154 Mon Sep 17 00:00:00 2001 From: Simon Date: Tue, 7 Nov 2023 13:01:49 +0100 Subject: [PATCH] helm: make scrape timeout configurable --- charts/extended-ceph-exporter/README.md | 1 + charts/extended-ceph-exporter/templates/servicemonitor.yaml | 1 + charts/extended-ceph-exporter/values.yaml | 2 ++ 3 files changed, 4 insertions(+) diff --git a/charts/extended-ceph-exporter/README.md b/charts/extended-ceph-exporter/README.md index 7e2039a..44cf7a5 100644 --- a/charts/extended-ceph-exporter/README.md +++ b/charts/extended-ceph-exporter/README.md @@ -84,4 +84,5 @@ _See [helm uninstall](https://helm.sh/docs/helm/helm_uninstall/) for command doc | serviceMonitor.enabled | bool | `false` | Specifies whether a prometheus-operator ServiceMonitor should be created | | serviceMonitor.namespaceSelector | string | `nil` | | | serviceMonitor.scrapeInterval | duration | `"30s"` | Interval at which metrics should be scraped | +| serviceMonitor.scrapeTimeout | duration | `"20s"` | Timeout for scraping | | tolerations | list | `[]` | [Tolerations](https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/) | diff --git a/charts/extended-ceph-exporter/templates/servicemonitor.yaml b/charts/extended-ceph-exporter/templates/servicemonitor.yaml index 8f6931d..4d8bb2e 100644 --- a/charts/extended-ceph-exporter/templates/servicemonitor.yaml +++ b/charts/extended-ceph-exporter/templates/servicemonitor.yaml @@ -15,6 +15,7 @@ spec: endpoints: - port: http-metrics interval: {{ .Values.serviceMonitor.scrapeInterval }} + scrapeTimeout: {{ .Values.serviceMonitor.scrapeTimeout }} {{- if .Values.serviceMonitor.honorLabels }} honorLabels: true {{- end }} diff --git a/charts/extended-ceph-exporter/values.yaml b/charts/extended-ceph-exporter/values.yaml index f7680b7..18dc901 100644 --- a/charts/extended-ceph-exporter/values.yaml +++ b/charts/extended-ceph-exporter/values.yaml @@ -94,6 +94,8 @@ serviceMonitor: # any: true # -- (duration) Interval at which metrics should be scraped scrapeInterval: 30s + # -- (duration) Timeout for scraping + scrapeTimeout: 20s # honorLabels: true prometheusRule: