mirror of https://git.rancher.io/charts
Rebase to ba91bdb2d79ca4419cf72078f5f4bfcc426d4599
parent
00db29b544
commit
ef23466ebc
|
@ -0,0 +1,28 @@
|
|||
{{- if and .Values.prometheus.enabled .Values.prometheus.thanosServiceExternal.enabled }}
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: {{ template "kube-prometheus-stack.fullname" . }}-thanos-external
|
||||
namespace: {{ template "kube-prometheus-stack.namespace" . }}
|
||||
labels:
|
||||
{{ include "kube-prometheus-stack.labels" . | indent 4 }}
|
||||
{{- if .Values.prometheus.thanosServiceExternal.labels }}
|
||||
{{ toYaml .Values.prometheus.thanosServiceExternal.labels | indent 4 }}
|
||||
{{- end }}
|
||||
{{- if .Values.prometheus.thanosServiceExternal.annotations }}
|
||||
annotations:
|
||||
{{ toYaml .Values.prometheus.thanosServiceExternal.annotations | indent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
type: {{ .Values.prometheus.thanosServiceExternal.type }}
|
||||
ports:
|
||||
- name: {{ .Values.prometheus.thanosServiceExternal.portName }}
|
||||
port: {{ .Values.prometheus.thanosServiceExternal.port }}
|
||||
targetPort: {{ .Values.prometheus.thanosServiceExternal.targetPort }}
|
||||
{{- if eq .Values.prometheus.thanosServiceExternal.type "NodePort" }}
|
||||
nodePort: {{ .Values.prometheus.thanosServiceExternal.nodePort }}
|
||||
{{- end }}
|
||||
selector:
|
||||
app.kubernetes.io/name: prometheus
|
||||
prometheus: {{ template "kube-prometheus-stack.fullname" . }}-prometheus
|
||||
{{- end }}
|
|
@ -1,9 +1,47 @@
|
|||
--- charts-original/Chart.yaml
|
||||
+++ charts/Chart.yaml
|
||||
@@ -5,6 +5,15 @@
|
||||
@@ -1,3 +1,35 @@
|
||||
+apiVersion: v2
|
||||
+description: Collects several related Helm charts, Grafana dashboards, and Prometheus rules combined with documentation and scripts to provide easy to operate end-to-end Kubernetes cluster monitoring with Prometheus using the Prometheus Operator.
|
||||
+icon: https://raw.githubusercontent.com/prometheus/prometheus.github.io/master/assets/prometheus_logo-cb55bb5c346.png
|
||||
+engine: gotpl
|
||||
+type: application
|
||||
+maintainers:
|
||||
+ - name: vsliouniaev
|
||||
+ - name: bismarck
|
||||
+ - name: gianrubio
|
||||
+ email: gianrubio@gmail.com
|
||||
+ - name: gkarthiks
|
||||
+ email: github.gkarthiks@gmail.com
|
||||
+ - name: scottrigby
|
||||
+ email: scott@r6by.com
|
||||
+ - name: Xtigyro
|
||||
+ email: miroslav.hadzhiev@gmail.com
|
||||
+ - name: Arvind
|
||||
+ email: arvind.iyengar@suse.com
|
||||
+ url: ""
|
||||
+name: rancher-monitoring
|
||||
+sources:
|
||||
+ - https://github.com/prometheus-community/helm-charts
|
||||
+ - https://github.com/prometheus-operator/kube-prometheus
|
||||
+version: 16.6.0
|
||||
+appVersion: 0.48.0
|
||||
+kubeVersion: ">=1.16.0-0"
|
||||
+home: https://github.com/prometheus-operator/kube-prometheus
|
||||
+keywords:
|
||||
+- operator
|
||||
+- prometheus
|
||||
+- kube-prometheus
|
||||
+- monitoring
|
||||
annotations:
|
||||
artifacthub.io/links: |
|
||||
- name: Chart Source
|
||||
@@ -5,8 +37,15 @@
|
||||
- name: Upstream Project
|
||||
url: https://github.com/prometheus-operator/kube-prometheus
|
||||
artifacthub.io/operator: "true"
|
||||
-apiVersion: v2
|
||||
-appVersion: 0.46.0
|
||||
+ catalog.cattle.io/certified: rancher
|
||||
+ catalog.cattle.io/namespace: cattle-monitoring-system
|
||||
+ catalog.cattle.io/release-name: rancher-monitoring
|
||||
|
@ -13,10 +51,10 @@
|
|||
+ catalog.cattle.io/auto-install: rancher-monitoring-crd=match
|
||||
+ catalog.cattle.io/requests-cpu: "4500m"
|
||||
+ catalog.cattle.io/requests-memory: "4000Mi"
|
||||
apiVersion: v2
|
||||
appVersion: 0.46.0
|
||||
dependencies:
|
||||
@@ -71,19 +80,17 @@
|
||||
- condition: grafana.enabled
|
||||
name: grafana
|
||||
@@ -71,34 +110,6 @@
|
||||
- condition: rkeScheduler.enabled
|
||||
name: rkeScheduler
|
||||
repository: file://./charts/rkeScheduler
|
||||
|
@ -28,29 +66,27 @@
|
|||
- and Prometheus rules combined with documentation and scripts to provide easy to
|
||||
- operate end-to-end Kubernetes cluster monitoring with Prometheus using the Prometheus
|
||||
- Operator.
|
||||
+description: Collects several related Helm charts, Grafana dashboards, and Prometheus rules combined with documentation and scripts to provide easy to operate end-to-end Kubernetes cluster monitoring with Prometheus using the Prometheus Operator.
|
||||
home: https://github.com/prometheus-operator/kube-prometheus
|
||||
icon: https://raw.githubusercontent.com/prometheus/prometheus.github.io/master/assets/prometheus_logo-cb55bb5c346.png
|
||||
keywords:
|
||||
- operator
|
||||
- prometheus
|
||||
- kube-prometheus
|
||||
+- monitoring
|
||||
kubeVersion: '>=1.16.0-0'
|
||||
maintainers:
|
||||
- name: vsliouniaev
|
||||
@@ -96,9 +103,12 @@
|
||||
name: scottrigby
|
||||
- email: miroslav.hadzhiev@gmail.com
|
||||
name: Xtigyro
|
||||
-home: https://github.com/prometheus-operator/kube-prometheus
|
||||
-icon: https://raw.githubusercontent.com/prometheus/prometheus.github.io/master/assets/prometheus_logo-cb55bb5c346.png
|
||||
-keywords:
|
||||
-- operator
|
||||
-- prometheus
|
||||
-- kube-prometheus
|
||||
-kubeVersion: '>=1.16.0-0'
|
||||
-maintainers:
|
||||
-- name: vsliouniaev
|
||||
-- name: bismarck
|
||||
-- email: gianrubio@gmail.com
|
||||
- name: gianrubio
|
||||
-- email: github.gkarthiks@gmail.com
|
||||
- name: gkarthiks
|
||||
-- email: scott@r6by.com
|
||||
- name: scottrigby
|
||||
-- email: miroslav.hadzhiev@gmail.com
|
||||
- name: Xtigyro
|
||||
-name: kube-prometheus-stack
|
||||
+- name: Arvind
|
||||
+ email: arvind.iyengar@suse.com
|
||||
+ url: ""
|
||||
+name: rancher-monitoring
|
||||
sources:
|
||||
- https://github.com/prometheus-community/helm-charts
|
||||
- https://github.com/prometheus-operator/kube-prometheus
|
||||
type: application
|
||||
-sources:
|
||||
-- https://github.com/prometheus-community/helm-charts
|
||||
-- https://github.com/prometheus-operator/kube-prometheus
|
||||
-type: application
|
||||
-version: 14.5.0
|
||||
+version: 14.5.1
|
||||
|
|
|
@ -1,6 +1,51 @@
|
|||
--- charts-original/README.md
|
||||
+++ charts/README.md
|
||||
@@ -171,7 +171,43 @@
|
||||
@@ -35,7 +35,7 @@
|
||||
|
||||
By default this chart installs additional, dependent charts:
|
||||
|
||||
-- [kubernetes/kube-state-metrics](https://github.com/kubernetes/kube-state-metrics/tree/master/charts/kube-state-metrics)
|
||||
+- [prometheus-community/kube-state-metrics](https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-state-metrics)
|
||||
- [prometheus-community/prometheus-node-exporter](https://github.com/prometheus-community/helm-charts/tree/main/charts/prometheus-node-exporter)
|
||||
- [grafana/grafana](https://github.com/grafana/helm-charts/tree/main/charts/grafana)
|
||||
|
||||
@@ -83,6 +83,22 @@
|
||||
|
||||
A major chart version change (like v1.2.3 -> v2.0.0) indicates that there is an incompatible breaking change needing manual actions.
|
||||
|
||||
+### From 15.x to 16.x
|
||||
+Version 16 upgrades kube-state-metrics to v2.0.0. This includes changed command-line arguments and removed metrics, see this [blog post](https://kubernetes.io/blog/2021/04/13/kube-state-metrics-v-2-0/). This version also removes Grafana dashboards that supported Kubernetes 1.14 or earlier.
|
||||
+
|
||||
+### From 14.x to 15.x
|
||||
+Version 15 upgrades prometheus-operator from 0.46.x to 0.47.x. Helm does not automatically upgrade or install new CRDs on a chart upgrade, so you have to install the CRDs manually before updating:
|
||||
+
|
||||
+```console
|
||||
+kubectl apply -f https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.47.0/example/prometheus-operator-crd/monitoring.coreos.com_alertmanagerconfigs.yaml
|
||||
+kubectl apply -f https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.47.0/example/prometheus-operator-crd/monitoring.coreos.com_alertmanagers.yaml
|
||||
+kubectl apply -f https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.47.0/example/prometheus-operator-crd/monitoring.coreos.com_podmonitors.yaml
|
||||
+kubectl apply -f https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.47.0/example/prometheus-operator-crd/monitoring.coreos.com_probes.yaml
|
||||
+kubectl apply -f https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.47.0/example/prometheus-operator-crd/monitoring.coreos.com_prometheuses.yaml
|
||||
+kubectl apply -f https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.47.0/example/prometheus-operator-crd/monitoring.coreos.com_servicemonitors.yaml
|
||||
+kubectl apply -f https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.47.0/example/prometheus-operator-crd/monitoring.coreos.com_thanosrulers.yaml
|
||||
+```
|
||||
+
|
||||
### From 13.x to 14.x
|
||||
|
||||
Version 14 upgrades prometheus-operator from 0.45.x to 0.46.x. Helm does not automatically upgrade or install new CRDs on a chart upgrade, so you have to install the CRDs manually before updating:
|
||||
@@ -109,6 +125,12 @@
|
||||
|
||||
### From 11.x to 12.x
|
||||
|
||||
+Version 12 upgrades prometheus-operator from 0.43.x to 0.44.x. Helm does not automatically upgrade or install new CRDs on a chart upgrade, so you have to install the CRD manually before updating:
|
||||
+
|
||||
+```console
|
||||
+kubectl apply -f https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/release-0.44/example/prometheus-operator-crd/monitoring.coreos.com_prometheuses.yaml
|
||||
+```
|
||||
+
|
||||
The chart was migrated to support only helm v3 and later.
|
||||
|
||||
### From 10.x to 11.x
|
||||
@@ -171,7 +193,43 @@
|
||||
helm show values prometheus-community/kube-prometheus-stack
|
||||
```
|
||||
|
||||
|
@ -45,3 +90,12 @@
|
|||
|
||||
### Multiple releases
|
||||
|
||||
@@ -373,7 +431,7 @@
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
labels:
|
||||
- app: prometheus
|
||||
+ app.kubernetes.io/name: prometheus
|
||||
prometheus: prometheus-migration-prometheus
|
||||
name: prometheus-prometheus-migration-prometheus-db-prometheus-prometheus-migration-prometheus-0
|
||||
namespace: monitoring
|
||||
|
|
|
@ -0,0 +1,8 @@
|
|||
--- charts-original/crds/crd-alertmanagerconfigs.yaml
|
||||
+++ charts/crds/crd-alertmanagerconfigs.yaml
|
||||
@@ -1,4 +1,4 @@
|
||||
-# https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.46.0/example/prometheus-operator-crd/monitoring.coreos.com_alertmanagerconfigs.yaml
|
||||
+# https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.48.0/example/prometheus-operator-crd/monitoring.coreos.com_alertmanagerconfigs.yaml
|
||||
|
||||
---
|
||||
apiVersion: apiextensions.k8s.io/v1
|
|
@ -0,0 +1,8 @@
|
|||
--- charts-original/crds/crd-alertmanagers.yaml
|
||||
+++ charts/crds/crd-alertmanagers.yaml
|
||||
@@ -1,4 +1,4 @@
|
||||
-# https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.46.0/example/prometheus-operator-crd/monitoring.coreos.com_alertmanagers.yaml
|
||||
+# https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.48.0/example/prometheus-operator-crd/monitoring.coreos.com_alertmanagers.yaml
|
||||
|
||||
---
|
||||
apiVersion: apiextensions.k8s.io/v1
|
|
@ -0,0 +1,17 @@
|
|||
--- charts-original/crds/crd-podmonitors.yaml
|
||||
+++ charts/crds/crd-podmonitors.yaml
|
||||
@@ -1,4 +1,4 @@
|
||||
-# https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.46.0/example/prometheus-operator-crd/monitoring.coreos.com_podmonitors.yaml
|
||||
+# https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.48.0/example/prometheus-operator-crd/monitoring.coreos.com_podmonitors.yaml
|
||||
|
||||
---
|
||||
apiVersion: apiextensions.k8s.io/v1
|
||||
@@ -161,7 +161,7 @@
|
||||
description: ProxyURL eg http://proxyserver:2195 Directs scrapes to proxy through this endpoint.
|
||||
type: string
|
||||
relabelings:
|
||||
- description: 'RelabelConfigs to apply to samples before ingestion. More info: https://prometheus.io/docs/prometheus/latest/configuration/configuration/#relabel_config'
|
||||
+ description: 'RelabelConfigs to apply to samples before scraping. Prometheus Operator automatically adds relabelings for a few standard Kubernetes fields and replaces original scrape job name with __tmp_prometheus_job_name. More info: https://prometheus.io/docs/prometheus/latest/configuration/configuration/#relabel_config'
|
||||
items:
|
||||
description: 'RelabelConfig allows dynamic rewriting of the label set, being applied to samples before ingestion. It defines `<metric_relabel_configs>`-section of Prometheus configuration. More info: https://prometheus.io/docs/prometheus/latest/configuration/configuration/#metric_relabel_configs'
|
||||
properties:
|
|
@ -0,0 +1,164 @@
|
|||
--- charts-original/crds/crd-probes.yaml
|
||||
+++ charts/crds/crd-probes.yaml
|
||||
@@ -1,4 +1,4 @@
|
||||
-# https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.46.0/example/prometheus-operator-crd/monitoring.coreos.com_probes.yaml
|
||||
+# https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.48.0/example/prometheus-operator-crd/monitoring.coreos.com_probes.yaml
|
||||
|
||||
---
|
||||
apiVersion: apiextensions.k8s.io/v1
|
||||
@@ -35,6 +35,55 @@
|
||||
spec:
|
||||
description: Specification of desired Ingress selection for target discovery by Prometheus.
|
||||
properties:
|
||||
+ basicAuth:
|
||||
+ description: 'BasicAuth allow an endpoint to authenticate over basic authentication. More info: https://prometheus.io/docs/operating/configuration/#endpoint'
|
||||
+ properties:
|
||||
+ password:
|
||||
+ description: The secret in the service monitor namespace that contains the password for authentication.
|
||||
+ properties:
|
||||
+ key:
|
||||
+ description: The key of the secret to select from. Must be a valid secret key.
|
||||
+ type: string
|
||||
+ name:
|
||||
+ description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?'
|
||||
+ type: string
|
||||
+ optional:
|
||||
+ description: Specify whether the Secret or its key must be defined
|
||||
+ type: boolean
|
||||
+ required:
|
||||
+ - key
|
||||
+ type: object
|
||||
+ username:
|
||||
+ description: The secret in the service monitor namespace that contains the username for authentication.
|
||||
+ properties:
|
||||
+ key:
|
||||
+ description: The key of the secret to select from. Must be a valid secret key.
|
||||
+ type: string
|
||||
+ name:
|
||||
+ description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?'
|
||||
+ type: string
|
||||
+ optional:
|
||||
+ description: Specify whether the Secret or its key must be defined
|
||||
+ type: boolean
|
||||
+ required:
|
||||
+ - key
|
||||
+ type: object
|
||||
+ type: object
|
||||
+ bearerTokenSecret:
|
||||
+ description: Secret to mount to read bearer token for scraping targets. The secret needs to be in the same namespace as the probe and accessible by the Prometheus Operator.
|
||||
+ properties:
|
||||
+ key:
|
||||
+ description: The key of the secret to select from. Must be a valid secret key.
|
||||
+ type: string
|
||||
+ name:
|
||||
+ description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?'
|
||||
+ type: string
|
||||
+ optional:
|
||||
+ description: Specify whether the Secret or its key must be defined
|
||||
+ type: boolean
|
||||
+ required:
|
||||
+ - key
|
||||
+ type: object
|
||||
interval:
|
||||
description: Interval at which targets are probed using the configured prober. If not specified Prometheus' global scrape interval is used.
|
||||
type: string
|
||||
@@ -188,6 +237,99 @@
|
||||
type: array
|
||||
type: object
|
||||
type: object
|
||||
+ tlsConfig:
|
||||
+ description: TLS configuration to use when scraping the endpoint.
|
||||
+ properties:
|
||||
+ ca:
|
||||
+ description: Struct containing the CA cert to use for the targets.
|
||||
+ properties:
|
||||
+ configMap:
|
||||
+ description: ConfigMap containing data to use for the targets.
|
||||
+ properties:
|
||||
+ key:
|
||||
+ description: The key to select.
|
||||
+ type: string
|
||||
+ name:
|
||||
+ description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?'
|
||||
+ type: string
|
||||
+ optional:
|
||||
+ description: Specify whether the ConfigMap or its key must be defined
|
||||
+ type: boolean
|
||||
+ required:
|
||||
+ - key
|
||||
+ type: object
|
||||
+ secret:
|
||||
+ description: Secret containing data to use for the targets.
|
||||
+ properties:
|
||||
+ key:
|
||||
+ description: The key of the secret to select from. Must be a valid secret key.
|
||||
+ type: string
|
||||
+ name:
|
||||
+ description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?'
|
||||
+ type: string
|
||||
+ optional:
|
||||
+ description: Specify whether the Secret or its key must be defined
|
||||
+ type: boolean
|
||||
+ required:
|
||||
+ - key
|
||||
+ type: object
|
||||
+ type: object
|
||||
+ cert:
|
||||
+ description: Struct containing the client cert file for the targets.
|
||||
+ properties:
|
||||
+ configMap:
|
||||
+ description: ConfigMap containing data to use for the targets.
|
||||
+ properties:
|
||||
+ key:
|
||||
+ description: The key to select.
|
||||
+ type: string
|
||||
+ name:
|
||||
+ description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?'
|
||||
+ type: string
|
||||
+ optional:
|
||||
+ description: Specify whether the ConfigMap or its key must be defined
|
||||
+ type: boolean
|
||||
+ required:
|
||||
+ - key
|
||||
+ type: object
|
||||
+ secret:
|
||||
+ description: Secret containing data to use for the targets.
|
||||
+ properties:
|
||||
+ key:
|
||||
+ description: The key of the secret to select from. Must be a valid secret key.
|
||||
+ type: string
|
||||
+ name:
|
||||
+ description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?'
|
||||
+ type: string
|
||||
+ optional:
|
||||
+ description: Specify whether the Secret or its key must be defined
|
||||
+ type: boolean
|
||||
+ required:
|
||||
+ - key
|
||||
+ type: object
|
||||
+ type: object
|
||||
+ insecureSkipVerify:
|
||||
+ description: Disable target certificate validation.
|
||||
+ type: boolean
|
||||
+ keySecret:
|
||||
+ description: Secret containing the client key file for the targets.
|
||||
+ properties:
|
||||
+ key:
|
||||
+ description: The key of the secret to select from. Must be a valid secret key.
|
||||
+ type: string
|
||||
+ name:
|
||||
+ description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?'
|
||||
+ type: string
|
||||
+ optional:
|
||||
+ description: Specify whether the Secret or its key must be defined
|
||||
+ type: boolean
|
||||
+ required:
|
||||
+ - key
|
||||
+ type: object
|
||||
+ serverName:
|
||||
+ description: Used to verify the hostname for the targets.
|
||||
+ type: string
|
||||
+ type: object
|
||||
type: object
|
||||
required:
|
||||
- spec
|
|
@ -0,0 +1,55 @@
|
|||
--- charts-original/crds/crd-prometheuses.yaml
|
||||
+++ charts/crds/crd-prometheuses.yaml
|
||||
@@ -1,4 +1,4 @@
|
||||
-# https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.46.0/example/prometheus-operator-crd/monitoring.coreos.com_prometheuses.yaml
|
||||
+# https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.48.0/example/prometheus-operator-crd/monitoring.coreos.com_prometheuses.yaml
|
||||
|
||||
---
|
||||
apiVersion: apiextensions.k8s.io/v1
|
||||
@@ -1467,6 +1467,11 @@
|
||||
enableAdminAPI:
|
||||
description: 'Enable access to prometheus web admin API. Defaults to the value of `false`. WARNING: Enabling the admin APIs enables mutating endpoints, to delete data, shutdown Prometheus, and more. Enabling this should be done with care and the user is advised to add additional authentication authorization via a proxy to ensure only clients authorized to perform these actions can do so. For more information see https://prometheus.io/docs/prometheus/latest/querying/api/#tsdb-admin-apis'
|
||||
type: boolean
|
||||
+ enableFeatures:
|
||||
+ description: Enable access to Prometheus disabled features. By default, no features are enabled. Enabling disabled features is entirely outside the scope of what the maintainers will support and by doing so, you accept that this behaviour may break at any time without notice. For more information see https://prometheus.io/docs/prometheus/latest/disabled_features/
|
||||
+ items:
|
||||
+ type: string
|
||||
+ type: array
|
||||
enforcedNamespaceLabel:
|
||||
description: EnforcedNamespaceLabel enforces adding a namespace label of origin for each alert and metric that is user created. The label value will always be the namespace of the object that is being created.
|
||||
type: string
|
||||
@@ -2465,7 +2470,7 @@
|
||||
type: object
|
||||
type: object
|
||||
bearerToken:
|
||||
- description: bearer token for remote read.
|
||||
+ description: Bearer token for remote read.
|
||||
type: string
|
||||
bearerTokenFile:
|
||||
description: File to read bearer token for remote read.
|
||||
@@ -2636,7 +2641,7 @@
|
||||
type: object
|
||||
type: object
|
||||
bearerToken:
|
||||
- description: File to read bearer token for remote write.
|
||||
+ description: Bearer token for remote write.
|
||||
type: string
|
||||
bearerTokenFile:
|
||||
description: File to read bearer token for remote write.
|
||||
@@ -2646,6 +2651,16 @@
|
||||
type: string
|
||||
description: Custom HTTP headers to be sent along with each remote write request. Be aware that headers that are set by Prometheus itself can't be overwritten. Only valid in Prometheus versions 2.25.0 and newer.
|
||||
type: object
|
||||
+ metadataConfig:
|
||||
+ description: MetadataConfig configures the sending of series metadata to remote storage.
|
||||
+ properties:
|
||||
+ send:
|
||||
+ description: Whether metric metadata is sent to remote storage or not.
|
||||
+ type: boolean
|
||||
+ sendInterval:
|
||||
+ description: How frequently metric metadata is sent to remote storage.
|
||||
+ type: string
|
||||
+ type: object
|
||||
name:
|
||||
description: The name of the remote write queue, must be unique if specified. The name is used in metrics and logging in order to differentiate queues. Only valid in Prometheus versions 2.15.0 and newer.
|
||||
type: string
|
|
@ -0,0 +1,8 @@
|
|||
--- charts-original/crds/crd-prometheusrules.yaml
|
||||
+++ charts/crds/crd-prometheusrules.yaml
|
||||
@@ -1,4 +1,4 @@
|
||||
-# https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.46.0/example/prometheus-operator-crd/monitoring.coreos.com_prometheusrules.yaml
|
||||
+# https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.48.0/example/prometheus-operator-crd/monitoring.coreos.com_prometheusrules.yaml
|
||||
|
||||
---
|
||||
apiVersion: apiextensions.k8s.io/v1
|
|
@ -0,0 +1,17 @@
|
|||
--- charts-original/crds/crd-servicemonitors.yaml
|
||||
+++ charts/crds/crd-servicemonitors.yaml
|
||||
@@ -1,4 +1,4 @@
|
||||
-# https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.46.0/example/prometheus-operator-crd/monitoring.coreos.com_servicemonitors.yaml
|
||||
+# https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.48.0/example/prometheus-operator-crd/monitoring.coreos.com_servicemonitors.yaml
|
||||
|
||||
---
|
||||
apiVersion: apiextensions.k8s.io/v1
|
||||
@@ -149,7 +149,7 @@
|
||||
description: ProxyURL eg http://proxyserver:2195 Directs scrapes to proxy through this endpoint.
|
||||
type: string
|
||||
relabelings:
|
||||
- description: 'RelabelConfigs to apply to samples before scraping. More info: https://prometheus.io/docs/prometheus/latest/configuration/configuration/#relabel_config'
|
||||
+ description: 'RelabelConfigs to apply to samples before scraping. Prometheus Operator automatically adds relabelings for a few standard Kubernetes fields and replaces original scrape job name with __tmp_prometheus_job_name. More info: https://prometheus.io/docs/prometheus/latest/configuration/configuration/#relabel_config'
|
||||
items:
|
||||
description: 'RelabelConfig allows dynamic rewriting of the label set, being applied to samples before ingestion. It defines `<metric_relabel_configs>`-section of Prometheus configuration. More info: https://prometheus.io/docs/prometheus/latest/configuration/configuration/#metric_relabel_configs'
|
||||
properties:
|
|
@ -0,0 +1,15 @@
|
|||
--- charts-original/crds/crd-thanosrulers.yaml
|
||||
+++ charts/crds/crd-thanosrulers.yaml
|
||||
@@ -1,4 +1,4 @@
|
||||
-# https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.46.0/example/prometheus-operator-crd/monitoring.coreos.com_thanosrulers.yaml
|
||||
+# https://raw.githubusercontent.com/prometheus-operator/prometheus-operator/v0.48.0/example/prometheus-operator-crd/monitoring.coreos.com_thanosrulers.yaml
|
||||
|
||||
---
|
||||
apiVersion: apiextensions.k8s.io/v1
|
||||
@@ -3339,4 +3339,4 @@
|
||||
kind: ""
|
||||
plural: ""
|
||||
conditions: []
|
||||
- storedVersions: []
|
||||
\ No newline at end of file
|
||||
+ storedVersions: []
|
|
@ -131,3 +131,48 @@
|
|||
{{/* vim: set filetype=mustache: */}}
|
||||
{{/* Expand the name of the chart. This is suffixed with -alertmanager, which means subtract 13 from longest 63 available */}}
|
||||
{{- define "kube-prometheus-stack.name" -}}
|
||||
@@ -46,6 +173,10 @@
|
||||
|
||||
{{/* Generate basic labels */}}
|
||||
{{- define "kube-prometheus-stack.labels" }}
|
||||
+app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||
+app.kubernetes.io/instance: {{ .Release.Name }}
|
||||
+app.kubernetes.io/version: "{{ .Chart.Version }}"
|
||||
+app.kubernetes.io/part-of: {{ template "kube-prometheus-stack.name" . }}
|
||||
chart: {{ template "kube-prometheus-stack.chartref" . }}
|
||||
release: {{ $.Release.Name | quote }}
|
||||
heritage: {{ $.Release.Service | quote }}
|
||||
@@ -90,4 +221,31 @@
|
||||
{{- else -}}
|
||||
{{- .Release.Namespace -}}
|
||||
{{- end -}}
|
||||
-{{- end -}}
|
||||
\ No newline at end of file
|
||||
+{{- end -}}
|
||||
+
|
||||
+{{/* Allow KubeVersion to be overridden. */}}
|
||||
+{{- define "kube-prometheus-stack.ingress.kubeVersion" -}}
|
||||
+ {{- default .Capabilities.KubeVersion.Version .Values.kubeVersionOverride -}}
|
||||
+{{- end -}}
|
||||
+
|
||||
+{{/* Get Ingress API Version */}}
|
||||
+{{- define "kube-prometheus-stack.ingress.apiVersion" -}}
|
||||
+ {{- if and (.Capabilities.APIVersions.Has "networking.k8s.io/v1") (semverCompare ">= 1.19.x" (include "kube-prometheus-stack.ingress.kubeVersion" .)) -}}
|
||||
+ {{- print "networking.k8s.io/v1" -}}
|
||||
+ {{- else if .Capabilities.APIVersions.Has "networking.k8s.io/v1beta1" -}}
|
||||
+ {{- print "networking.k8s.io/v1beta1" -}}
|
||||
+ {{- else -}}
|
||||
+ {{- print "extensions/v1beta1" -}}
|
||||
+ {{- end -}}
|
||||
+{{- end -}}
|
||||
+
|
||||
+{{/* Check Ingress stability */}}
|
||||
+{{- define "kube-prometheus-stack.ingress.isStable" -}}
|
||||
+ {{- eq (include "kube-prometheus-stack.ingress.apiVersion" .) "networking.k8s.io/v1" -}}
|
||||
+{{- end -}}
|
||||
+
|
||||
+{{/* Check Ingress supports pathType */}}
|
||||
+{{/* pathType was added to networking.k8s.io/v1beta1 in Kubernetes 1.18 */}}
|
||||
+{{- define "kube-prometheus-stack.ingress.supportsPathType" -}}
|
||||
+ {{- or (eq (include "kube-prometheus-stack.ingress.isStable" .) "true") (and (eq (include "kube-prometheus-stack.ingress.apiVersion" .) "networking.k8s.io/v1beta1") (semverCompare ">= 1.18.x" (include "kube-prometheus-stack.ingress.kubeVersion" .))) -}}
|
||||
+{{- end -}}
|
||||
|
|
|
@ -1,7 +1,13 @@
|
|||
--- charts-original/templates/alertmanager/alertmanager.yaml
|
||||
+++ charts/templates/alertmanager/alertmanager.yaml
|
||||
@@ -9,7 +9,7 @@
|
||||
@@ -7,9 +7,13 @@
|
||||
labels:
|
||||
app: {{ template "kube-prometheus-stack.name" . }}-alertmanager
|
||||
{{ include "kube-prometheus-stack.labels" . | indent 4 }}
|
||||
+{{- if .Values.alertmanager.annotations }}
|
||||
+ annotations:
|
||||
+{{ toYaml .Values.alertmanager.annotations | indent 4 }}
|
||||
+{{- end }}
|
||||
spec:
|
||||
{{- if .Values.alertmanager.alertmanagerSpec.image }}
|
||||
- image: {{ .Values.alertmanager.alertmanagerSpec.image.repository }}:{{ .Values.alertmanager.alertmanagerSpec.image.tag }}
|
||||
|
@ -9,7 +15,7 @@
|
|||
version: {{ .Values.alertmanager.alertmanagerSpec.image.tag }}
|
||||
{{- if .Values.alertmanager.alertmanagerSpec.image.sha }}
|
||||
sha: {{ .Values.alertmanager.alertmanagerSpec.image.sha }}
|
||||
@@ -22,11 +22,13 @@
|
||||
@@ -22,11 +26,13 @@
|
||||
externalUrl: "{{ tpl .Values.alertmanager.alertmanagerSpec.externalUrl . }}"
|
||||
{{- else if and .Values.alertmanager.ingress.enabled .Values.alertmanager.ingress.hosts }}
|
||||
externalUrl: "http://{{ tpl (index .Values.alertmanager.ingress.hosts 0) . }}{{ .Values.alertmanager.alertmanagerSpec.routePrefix }}"
|
||||
|
@ -24,7 +30,16 @@
|
|||
{{ toYaml .Values.alertmanager.alertmanagerSpec.nodeSelector | indent 4 }}
|
||||
{{- end }}
|
||||
paused: {{ .Values.alertmanager.alertmanagerSpec.paused }}
|
||||
@@ -100,8 +102,8 @@
|
||||
@@ -87,7 +93,7 @@
|
||||
labelSelector:
|
||||
matchExpressions:
|
||||
- {key: app, operator: In, values: [alertmanager]}
|
||||
- - {key: prometheus, operator: In, values: [{{ template "kube-prometheus-stack.fullname" . }}-alertmanager]}
|
||||
+ - {key: alertmanager, operator: In, values: [{{ template "kube-prometheus-stack.fullname" . }}-alertmanager]}
|
||||
{{- else if eq .Values.alertmanager.alertmanagerSpec.podAntiAffinity "soft" }}
|
||||
podAntiAffinity:
|
||||
preferredDuringSchedulingIgnoredDuringExecution:
|
||||
@@ -100,8 +106,8 @@
|
||||
- {key: prometheus, operator: In, values: [{{ template "kube-prometheus-stack.fullname" . }}-alertmanager]}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
@ -34,7 +49,7 @@
|
|||
{{ toYaml .Values.alertmanager.alertmanagerSpec.tolerations | indent 4 }}
|
||||
{{- end }}
|
||||
{{- if .Values.alertmanager.alertmanagerSpec.topologySpreadConstraints }}
|
||||
@@ -136,10 +138,10 @@
|
||||
@@ -136,10 +142,10 @@
|
||||
{{ toYaml .Values.alertmanager.alertmanagerSpec.volumeMounts | indent 4 }}
|
||||
{{- end }}
|
||||
portName: {{ .Values.alertmanager.alertmanagerSpec.portName }}
|
||||
|
|
|
@ -0,0 +1,69 @@
|
|||
--- charts-original/templates/alertmanager/ingress.yaml
|
||||
+++ charts/templates/alertmanager/ingress.yaml
|
||||
@@ -4,11 +4,9 @@
|
||||
{{- $servicePort := .Values.alertmanager.service.port -}}
|
||||
{{- $routePrefix := list .Values.alertmanager.alertmanagerSpec.routePrefix }}
|
||||
{{- $paths := .Values.alertmanager.ingress.paths | default $routePrefix -}}
|
||||
-{{- if .Capabilities.APIVersions.Has "networking.k8s.io/v1beta1" }}
|
||||
-apiVersion: networking.k8s.io/v1beta1
|
||||
-{{ else }}
|
||||
-apiVersion: extensions/v1beta1
|
||||
-{{ end -}}
|
||||
+{{- $apiIsStable := eq (include "kube-prometheus-stack.ingress.isStable" .) "true" -}}
|
||||
+{{- $ingressSupportsPathType := eq (include "kube-prometheus-stack.ingress.supportsPathType" .) "true" -}}
|
||||
+apiVersion: {{ include "kube-prometheus-stack.ingress.apiVersion" . }}
|
||||
kind: Ingress
|
||||
metadata:
|
||||
name: {{ $serviceName }}
|
||||
@@ -24,7 +22,7 @@
|
||||
{{- end }}
|
||||
{{ include "kube-prometheus-stack.labels" . | indent 4 }}
|
||||
spec:
|
||||
- {{- if or (.Capabilities.APIVersions.Has "networking.k8s.io/v1") (.Capabilities.APIVersions.Has "networking.k8s.io/v1beta1") }}
|
||||
+ {{- if $apiIsStable }}
|
||||
{{- if .Values.alertmanager.ingress.ingressClassName }}
|
||||
ingressClassName: {{ .Values.alertmanager.ingress.ingressClassName }}
|
||||
{{- end }}
|
||||
@@ -37,25 +35,39 @@
|
||||
paths:
|
||||
{{- range $p := $paths }}
|
||||
- path: {{ tpl $p $ }}
|
||||
- {{- if $pathType }}
|
||||
+ {{- if and $pathType $ingressSupportsPathType }}
|
||||
pathType: {{ $pathType }}
|
||||
{{- end }}
|
||||
backend:
|
||||
+ {{- if $apiIsStable }}
|
||||
+ service:
|
||||
+ name: {{ $serviceName }}
|
||||
+ port:
|
||||
+ number: {{ $servicePort }}
|
||||
+ {{- else }}
|
||||
serviceName: {{ $serviceName }}
|
||||
servicePort: {{ $servicePort }}
|
||||
- {{- end -}}
|
||||
+ {{- end }}
|
||||
+ {{- end -}}
|
||||
{{- end -}}
|
||||
{{- else }}
|
||||
- http:
|
||||
paths:
|
||||
{{- range $p := $paths }}
|
||||
- path: {{ tpl $p $ }}
|
||||
- {{- if $pathType }}
|
||||
+ {{- if and $pathType $ingressSupportsPathType }}
|
||||
pathType: {{ $pathType }}
|
||||
{{- end }}
|
||||
backend:
|
||||
+ {{- if $apiIsStable }}
|
||||
+ service:
|
||||
+ name: {{ $serviceName }}
|
||||
+ port:
|
||||
+ number: {{ $servicePort }}
|
||||
+ {{- else }}
|
||||
serviceName: {{ $serviceName }}
|
||||
servicePort: {{ $servicePort }}
|
||||
+ {{- end }}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- if .Values.alertmanager.ingress.tls }}
|
|
@ -0,0 +1,61 @@
|
|||
--- charts-original/templates/alertmanager/ingressperreplica.yaml
|
||||
+++ charts/templates/alertmanager/ingressperreplica.yaml
|
||||
@@ -3,6 +3,8 @@
|
||||
{{- $count := .Values.alertmanager.alertmanagerSpec.replicas | int -}}
|
||||
{{- $servicePort := .Values.alertmanager.service.port -}}
|
||||
{{- $ingressValues := .Values.alertmanager.ingressPerReplica -}}
|
||||
+{{- $apiIsStable := eq (include "kube-prometheus-stack.ingress.isStable" .) "true" -}}
|
||||
+{{- $ingressSupportsPathType := eq (include "kube-prometheus-stack.ingress.supportsPathType" .) "true" -}}
|
||||
apiVersion: v1
|
||||
kind: List
|
||||
metadata:
|
||||
@@ -11,17 +13,13 @@
|
||||
items:
|
||||
{{ range $i, $e := until $count }}
|
||||
- kind: Ingress
|
||||
- {{- if $.Capabilities.APIVersions.Has "networking.k8s.io/v1beta1" }}
|
||||
- apiVersion: networking.k8s.io/v1beta1
|
||||
- {{ else }}
|
||||
- apiVersion: extensions/v1beta1
|
||||
- {{ end -}}
|
||||
+ apiVersion: {{ include "kube-prometheus-stack.ingress.apiVersion" $ }}
|
||||
metadata:
|
||||
name: {{ include "kube-prometheus-stack.fullname" $ }}-alertmanager-{{ $i }}
|
||||
namespace: {{ template "kube-prometheus-stack.namespace" $ }}
|
||||
labels:
|
||||
app: {{ include "kube-prometheus-stack.name" $ }}-alertmanager
|
||||
-{{ include "kube-prometheus-stack.labels" $ | indent 8 }}
|
||||
+ {{ include "kube-prometheus-stack.labels" $ | indent 8 }}
|
||||
{{- if $ingressValues.labels }}
|
||||
{{ toYaml $ingressValues.labels | indent 8 }}
|
||||
{{- end }}
|
||||
@@ -30,7 +28,7 @@
|
||||
{{ toYaml $ingressValues.annotations | indent 8 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
- {{- if or ($.Capabilities.APIVersions.Has "networking.k8s.io/v1") ($.Capabilities.APIVersions.Has "networking.k8s.io/v1beta1") }}
|
||||
+ {{- if $apiIsStable }}
|
||||
{{- if $ingressValues.ingressClassName }}
|
||||
ingressClassName: {{ $ingressValues.ingressClassName }}
|
||||
{{- end }}
|
||||
@@ -41,12 +39,19 @@
|
||||
paths:
|
||||
{{- range $p := $ingressValues.paths }}
|
||||
- path: {{ tpl $p $ }}
|
||||
- {{- if $pathType }}
|
||||
+ {{- if and $pathType $ingressSupportsPathType }}
|
||||
pathType: {{ $pathType }}
|
||||
{{- end }}
|
||||
backend:
|
||||
+ {{- if $apiIsStable }}
|
||||
+ service:
|
||||
+ name: {{ include "kube-prometheus-stack.fullname" $ }}-alertmanager-{{ $i }}
|
||||
+ port:
|
||||
+ number: {{ $servicePort }}
|
||||
+ {{- else }}
|
||||
serviceName: {{ include "kube-prometheus-stack.fullname" $ }}-alertmanager-{{ $i }}
|
||||
servicePort: {{ $servicePort }}
|
||||
+ {{- end }}
|
||||
{{- end -}}
|
||||
{{- if or $ingressValues.tlsSecretName $ingressValues.tlsSecretPerReplica.enabled }}
|
||||
tls:
|
|
@ -0,0 +1,18 @@
|
|||
--- charts-original/templates/alertmanager/serviceaccount.yaml
|
||||
+++ charts/templates/alertmanager/serviceaccount.yaml
|
||||
@@ -6,11 +6,15 @@
|
||||
namespace: {{ template "kube-prometheus-stack.namespace" . }}
|
||||
labels:
|
||||
app: {{ template "kube-prometheus-stack.name" . }}-alertmanager
|
||||
+ app.kubernetes.io/name: {{ template "kube-prometheus-stack.name" . }}-alertmanager
|
||||
+ app.kubernetes.io/component: alertmanager
|
||||
{{ include "kube-prometheus-stack.labels" . | indent 4 }}
|
||||
{{- if .Values.alertmanager.serviceAccount.annotations }}
|
||||
annotations:
|
||||
{{ toYaml .Values.alertmanager.serviceAccount.annotations | indent 4 }}
|
||||
{{- end }}
|
||||
+{{- if .Values.global.imagePullSecrets }}
|
||||
imagePullSecrets:
|
||||
{{ toYaml .Values.global.imagePullSecrets | indent 2 }}
|
||||
{{- end }}
|
||||
+{{- end }}
|
|
@ -0,0 +1,12 @@
|
|||
--- charts-original/templates/alertmanager/servicemonitor.yaml
|
||||
+++ charts/templates/alertmanager/servicemonitor.yaml
|
||||
@@ -21,6 +21,9 @@
|
||||
{{- if .Values.alertmanager.serviceMonitor.interval }}
|
||||
interval: {{ .Values.alertmanager.serviceMonitor.interval }}
|
||||
{{- end }}
|
||||
+ {{- if .Values.alertmanager.serviceMonitor.proxyUrl }}
|
||||
+ proxyUrl: {{ .Values.alertmanager.serviceMonitor.proxyUrl}}
|
||||
+ {{- end }}
|
||||
{{- if .Values.alertmanager.serviceMonitor.scheme }}
|
||||
scheme: {{ .Values.alertmanager.serviceMonitor.scheme }}
|
||||
{{- end }}
|
|
@ -9,3 +9,13 @@
|
|||
labels:
|
||||
app: {{ template "kube-prometheus-stack.name" . }}-coredns
|
||||
{{ include "kube-prometheus-stack.labels" . | indent 4 }}
|
||||
@@ -21,6 +21,9 @@
|
||||
{{- if .Values.coreDns.serviceMonitor.interval}}
|
||||
interval: {{ .Values.coreDns.serviceMonitor.interval }}
|
||||
{{- end }}
|
||||
+ {{- if .Values.coreDns.serviceMonitor.proxyUrl }}
|
||||
+ proxyUrl: {{ .Values.coreDns.serviceMonitor.proxyUrl}}
|
||||
+ {{- end }}
|
||||
bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
|
||||
{{- if .Values.coreDns.serviceMonitor.metricRelabelings }}
|
||||
metricRelabelings:
|
||||
|
|
|
@ -9,3 +9,24 @@
|
|||
labels:
|
||||
app: {{ template "kube-prometheus-stack.name" . }}-apiserver
|
||||
{{ include "kube-prometheus-stack.labels" . | indent 4 }}
|
||||
@@ -13,15 +13,18 @@
|
||||
{{- if .Values.kubeApiServer.serviceMonitor.interval }}
|
||||
interval: {{ .Values.kubeApiServer.serviceMonitor.interval }}
|
||||
{{- end }}
|
||||
+ {{- if .Values.kubeApiServer.serviceMonitor.proxyUrl }}
|
||||
+ proxyUrl: {{ .Values.kubeApiServer.serviceMonitor.proxyUrl}}
|
||||
+ {{- end }}
|
||||
port: https
|
||||
scheme: https
|
||||
{{- if .Values.kubeApiServer.serviceMonitor.metricRelabelings }}
|
||||
metricRelabelings:
|
||||
{{ tpl (toYaml .Values.kubeApiServer.serviceMonitor.metricRelabelings | indent 6) . }}
|
||||
{{- end }}
|
||||
-{{- if .Values.kubeApiServer.relabelings }}
|
||||
+{{- if .Values.kubeApiServer.serviceMonitor.relabelings }}
|
||||
relabelings:
|
||||
-{{ toYaml .Values.kubeApiServer.relabelings | indent 6 }}
|
||||
+{{ toYaml .Values.kubeApiServer.serviceMonitor.relabelings | indent 6 }}
|
||||
{{- end }}
|
||||
tlsConfig:
|
||||
caFile: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
|
||||
|
|
|
@ -9,3 +9,13 @@
|
|||
labels:
|
||||
app: {{ template "kube-prometheus-stack.name" . }}-kube-controller-manager
|
||||
{{ include "kube-prometheus-stack.labels" . | indent 4 }}
|
||||
@@ -22,6 +22,9 @@
|
||||
interval: {{ .Values.kubeControllerManager.serviceMonitor.interval }}
|
||||
{{- end }}
|
||||
bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
|
||||
+ {{- if .Values.kubeControllerManager.serviceMonitor.proxyUrl }}
|
||||
+ proxyUrl: {{ .Values.kubeControllerManager.serviceMonitor.proxyUrl}}
|
||||
+ {{- end }}
|
||||
{{- if .Values.kubeControllerManager.serviceMonitor.https }}
|
||||
scheme: https
|
||||
tlsConfig:
|
||||
|
|
|
@ -9,3 +9,13 @@
|
|||
labels:
|
||||
app: {{ template "kube-prometheus-stack.name" . }}-kube-dns
|
||||
{{ include "kube-prometheus-stack.labels" . | indent 4 }}
|
||||
@@ -22,6 +22,9 @@
|
||||
interval: {{ .Values.kubeDns.serviceMonitor.interval }}
|
||||
{{- end }}
|
||||
bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
|
||||
+ {{- if .Values.kubeDns.serviceMonitor.proxyUrl }}
|
||||
+ proxyUrl: {{ .Values.kubeDns.serviceMonitor.proxyUrl}}
|
||||
+ {{- end }}
|
||||
{{- if .Values.kubeDns.serviceMonitor.dnsmasqMetricRelabelings }}
|
||||
metricRelabelings:
|
||||
{{ tpl (toYaml .Values.kubeDns.serviceMonitor.dnsmasqMetricRelabelings | indent 4) . }}
|
||||
|
|
|
@ -0,0 +1,12 @@
|
|||
--- charts-original/templates/exporters/kube-etcd/servicemonitor.yaml
|
||||
+++ charts/templates/exporters/kube-etcd/servicemonitor.yaml
|
||||
@@ -22,6 +22,9 @@
|
||||
interval: {{ .Values.kubeEtcd.serviceMonitor.interval }}
|
||||
{{- end }}
|
||||
bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
|
||||
+ {{- if .Values.kubeEtcd.serviceMonitor.proxyUrl }}
|
||||
+ proxyUrl: {{ .Values.kubeEtcd.serviceMonitor.proxyUrl}}
|
||||
+ {{- end }}
|
||||
{{- if eq .Values.kubeEtcd.serviceMonitor.scheme "https" }}
|
||||
scheme: https
|
||||
tlsConfig:
|
|
@ -0,0 +1,12 @@
|
|||
--- charts-original/templates/exporters/kube-proxy/servicemonitor.yaml
|
||||
+++ charts/templates/exporters/kube-proxy/servicemonitor.yaml
|
||||
@@ -22,6 +22,9 @@
|
||||
interval: {{ .Values.kubeProxy.serviceMonitor.interval }}
|
||||
{{- end }}
|
||||
bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
|
||||
+ {{- if .Values.kubeProxy.serviceMonitor.proxyUrl }}
|
||||
+ proxyUrl: {{ .Values.kubeProxy.serviceMonitor.proxyUrl}}
|
||||
+ {{- end }}
|
||||
{{- if .Values.kubeProxy.serviceMonitor.https }}
|
||||
scheme: https
|
||||
tlsConfig:
|
|
@ -0,0 +1,12 @@
|
|||
--- charts-original/templates/exporters/kube-scheduler/servicemonitor.yaml
|
||||
+++ charts/templates/exporters/kube-scheduler/servicemonitor.yaml
|
||||
@@ -22,6 +22,9 @@
|
||||
interval: {{ .Values.kubeScheduler.serviceMonitor.interval }}
|
||||
{{- end }}
|
||||
bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
|
||||
+ {{- if .Values.kubeScheduler.serviceMonitor.proxyUrl }}
|
||||
+ proxyUrl: {{ .Values.kubeScheduler.serviceMonitor.proxyUrl}}
|
||||
+ {{- end }}
|
||||
{{- if .Values.kubeScheduler.serviceMonitor.https }}
|
||||
scheme: https
|
||||
tlsConfig:
|
|
@ -0,0 +1,24 @@
|
|||
--- charts-original/templates/exporters/kube-state-metrics/serviceMonitor.yaml
|
||||
+++ charts/templates/exporters/kube-state-metrics/serviceMonitor.yaml
|
||||
@@ -14,6 +14,9 @@
|
||||
{{- if .Values.kubeStateMetrics.serviceMonitor.interval }}
|
||||
interval: {{ .Values.kubeStateMetrics.serviceMonitor.interval }}
|
||||
{{- end }}
|
||||
+ {{- if .Values.kubeStateMetrics.serviceMonitor.proxyUrl }}
|
||||
+ proxyUrl: {{ .Values.kubeStateMetrics.serviceMonitor.proxyUrl}}
|
||||
+ {{- end }}
|
||||
honorLabels: true
|
||||
{{- if .Values.kubeStateMetrics.serviceMonitor.metricRelabelings }}
|
||||
metricRelabelings:
|
||||
@@ -23,6 +26,11 @@
|
||||
relabelings:
|
||||
{{ toYaml .Values.kubeStateMetrics.serviceMonitor.relabelings | indent 4 }}
|
||||
{{- end }}
|
||||
+{{- if .Values.kubeStateMetrics.serviceMonitor.namespaceOverride }}
|
||||
+ namespaceSelector:
|
||||
+ matchNames:
|
||||
+ - {{ .Values.kubeStateMetrics.serviceMonitor.namespaceOverride }}
|
||||
+{{- end }}
|
||||
selector:
|
||||
matchLabels:
|
||||
{{- if .Values.kubeStateMetrics.serviceMonitor.selectorOverride }}
|
|
@ -15,7 +15,37 @@
|
|||
labels:
|
||||
app: {{ template "kube-prometheus-stack.name" . }}-kubelet
|
||||
{{- include "kube-prometheus-stack.labels" . | indent 4 }}
|
||||
@@ -76,7 +79,7 @@
|
||||
@@ -15,6 +18,9 @@
|
||||
{{- if .Values.kubelet.serviceMonitor.interval }}
|
||||
interval: {{ .Values.kubelet.serviceMonitor.interval }}
|
||||
{{- end }}
|
||||
+ {{- if .Values.kubelet.serviceMonitor.proxyUrl }}
|
||||
+ proxyUrl: {{ .Values.kubelet.serviceMonitor.proxyUrl }}
|
||||
+ {{- end }}
|
||||
tlsConfig:
|
||||
caFile: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
|
||||
insecureSkipVerify: true
|
||||
@@ -35,6 +41,9 @@
|
||||
{{- if .Values.kubelet.serviceMonitor.interval }}
|
||||
interval: {{ .Values.kubelet.serviceMonitor.interval }}
|
||||
{{- end }}
|
||||
+ {{- if .Values.kubelet.serviceMonitor.proxyUrl }}
|
||||
+ proxyUrl: {{ .Values.kubelet.serviceMonitor.proxyUrl }}
|
||||
+ {{- end }}
|
||||
{{- if .Values.kubelet.serviceMonitor.scrapeTimeout }}
|
||||
scrapeTimeout: {{ .Values.kubelet.serviceMonitor.scrapeTimeout }}
|
||||
{{- end }}
|
||||
@@ -59,6 +68,9 @@
|
||||
{{- if .Values.kubelet.serviceMonitor.interval }}
|
||||
interval: {{ .Values.kubelet.serviceMonitor.interval }}
|
||||
{{- end }}
|
||||
+ {{- if .Values.kubelet.serviceMonitor.proxyUrl }}
|
||||
+ proxyUrl: {{ .Values.kubelet.serviceMonitor.proxyUrl }}
|
||||
+ {{- end }}
|
||||
honorLabels: true
|
||||
tlsConfig:
|
||||
caFile: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
|
||||
@@ -76,10 +88,13 @@
|
||||
{{- if .Values.kubelet.serviceMonitor.resource }}
|
||||
- port: https-metrics
|
||||
scheme: https
|
||||
|
@ -24,7 +54,33 @@
|
|||
{{- if .Values.kubelet.serviceMonitor.interval }}
|
||||
interval: {{ .Values.kubelet.serviceMonitor.interval }}
|
||||
{{- end }}
|
||||
@@ -125,7 +128,7 @@
|
||||
+ {{- if .Values.kubelet.serviceMonitor.proxyUrl }}
|
||||
+ proxyUrl: {{ .Values.kubelet.serviceMonitor.proxyUrl }}
|
||||
+ {{- end }}
|
||||
honorLabels: true
|
||||
tlsConfig:
|
||||
caFile: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
|
||||
@@ -99,6 +114,9 @@
|
||||
{{- if .Values.kubelet.serviceMonitor.interval }}
|
||||
interval: {{ .Values.kubelet.serviceMonitor.interval }}
|
||||
{{- end }}
|
||||
+ {{- if .Values.kubelet.serviceMonitor.proxyUrl }}
|
||||
+ proxyUrl: {{ .Values.kubelet.serviceMonitor.proxyUrl }}
|
||||
+ {{- end }}
|
||||
honorLabels: true
|
||||
{{- if .Values.kubelet.serviceMonitor.metricRelabelings }}
|
||||
metricRelabelings:
|
||||
@@ -114,6 +132,9 @@
|
||||
{{- if .Values.kubelet.serviceMonitor.interval }}
|
||||
interval: {{ .Values.kubelet.serviceMonitor.interval }}
|
||||
{{- end }}
|
||||
+ {{- if .Values.kubelet.serviceMonitor.proxyUrl }}
|
||||
+ proxyUrl: {{ .Values.kubelet.serviceMonitor.proxyUrl }}
|
||||
+ {{- end }}
|
||||
honorLabels: true
|
||||
{{- if .Values.kubelet.serviceMonitor.cAdvisorMetricRelabelings }}
|
||||
metricRelabelings:
|
||||
@@ -125,10 +146,13 @@
|
||||
{{- end }}
|
||||
{{- if .Values.kubelet.serviceMonitor.resource }}
|
||||
- port: http-metrics
|
||||
|
@ -33,3 +89,16 @@
|
|||
{{- if .Values.kubelet.serviceMonitor.interval }}
|
||||
interval: {{ .Values.kubelet.serviceMonitor.interval }}
|
||||
{{- end }}
|
||||
+ {{- if .Values.kubelet.serviceMonitor.proxyUrl }}
|
||||
+ proxyUrl: {{ .Values.kubelet.serviceMonitor.proxyUrl }}
|
||||
+ {{- end }}
|
||||
honorLabels: true
|
||||
{{- if .Values.kubelet.serviceMonitor.resourceMetricRelabelings }}
|
||||
metricRelabelings:
|
||||
@@ -147,5 +171,6 @@
|
||||
- {{ .Values.kubelet.namespace }}
|
||||
selector:
|
||||
matchLabels:
|
||||
+ app.kubernetes.io/managed-by: prometheus-operator
|
||||
k8s-app: kubelet
|
||||
{{- end}}
|
||||
|
|
|
@ -9,3 +9,23 @@
|
|||
apiVersion: monitoring.coreos.com/v1
|
||||
kind: ServiceMonitor
|
||||
metadata:
|
||||
@@ -13,11 +16,19 @@
|
||||
matchLabels:
|
||||
app: prometheus-node-exporter
|
||||
release: {{ $.Release.Name }}
|
||||
+ {{- if (index .Values "prometheus-node-exporter" "namespaceOverride") }}
|
||||
+ namespaceSelector:
|
||||
+ matchNames:
|
||||
+ - {{ index .Values "prometheus-node-exporter" "namespaceOverride" }}
|
||||
+ {{- end }}
|
||||
endpoints:
|
||||
- port: metrics
|
||||
{{- if .Values.nodeExporter.serviceMonitor.interval }}
|
||||
interval: {{ .Values.nodeExporter.serviceMonitor.interval }}
|
||||
{{- end }}
|
||||
+ {{- if .Values.nodeExporter.serviceMonitor.proxyUrl }}
|
||||
+ proxyUrl: {{ .Values.nodeExporter.serviceMonitor.proxyUrl}}
|
||||
+ {{- end }}
|
||||
{{- if .Values.nodeExporter.serviceMonitor.scrapeTimeout }}
|
||||
scrapeTimeout: {{ .Values.nodeExporter.serviceMonitor.scrapeTimeout }}
|
||||
{{- end }}
|
||||
|
|
|
@ -1,5 +1,13 @@
|
|||
--- charts-original/templates/grafana/configmap-dashboards.yaml
|
||||
+++ charts/templates/grafana/configmap-dashboards.yaml
|
||||
@@ -1,5 +1,5 @@
|
||||
-{{- if and .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
-{{- $files := .Files.Glob "dashboards/*.json" }}
|
||||
+{{- if or (and .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled) .Values.grafana.forceDeployDashboards }}
|
||||
+{{- $files := .Files.Glob "dashboards-1.14/*.json" }}
|
||||
{{- if $files }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMapList
|
||||
@@ -10,7 +10,7 @@
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
--- charts-original/templates/grafana/configmaps-datasources.yaml
|
||||
+++ charts/templates/grafana/configmaps-datasources.yaml
|
||||
@@ -3,7 +3,7 @@
|
||||
@@ -1,9 +1,9 @@
|
||||
-{{- if and .Values.grafana.enabled .Values.grafana.sidecar.datasources.enabled }}
|
||||
+{{- if or (and .Values.grafana.enabled .Values.grafana.sidecar.datasources.enabled) .Values.grafana.forceDeployDatasources }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
name: {{ template "kube-prometheus-stack.fullname" . }}-grafana-datasource
|
||||
|
@ -9,3 +12,15 @@
|
|||
{{- if .Values.grafana.sidecar.datasources.annotations }}
|
||||
annotations:
|
||||
{{ toYaml .Values.grafana.sidecar.datasources.annotations | indent 4 }}
|
||||
@@ -20,7 +20,11 @@
|
||||
{{- if .Values.grafana.sidecar.datasources.defaultDatasourceEnabled }}
|
||||
- name: Prometheus
|
||||
type: prometheus
|
||||
+ {{- if .Values.grafana.sidecar.datasources.url }}
|
||||
+ url: {{ .Values.grafana.sidecar.datasources.url }}
|
||||
+ {{- else }}
|
||||
url: http://{{ template "kube-prometheus-stack.fullname" . }}-prometheus:{{ .Values.prometheus.service.port }}/{{ trimPrefix "/" .Values.prometheus.prometheusSpec.routePrefix }}
|
||||
+ {{- end }}
|
||||
access: proxy
|
||||
isDefault: true
|
||||
jsonData:
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/apiserver.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/apiserver.yaml
|
||||
@@ -8,7 +8,7 @@
|
||||
@@ -4,11 +4,11 @@
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled .Values.kubeApiServer.enabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled .Values.kubeApiServer.enabled }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
@ -9,3 +14,10 @@
|
|||
name: {{ printf "%s-%s" (include "kube-prometheus-stack.fullname" $) "apiserver" | trunc 63 | trimSuffix "-" }}
|
||||
annotations:
|
||||
{{ toYaml .Values.grafana.sidecar.dashboards.annotations | indent 4 }}
|
||||
@@ -1744,4 +1744,4 @@
|
||||
"uid": "09ec8aa1e996d6ffcd6817bbaff4db1b",
|
||||
"version": 0
|
||||
}
|
||||
-{{- end }}
|
||||
\ No newline at end of file
|
||||
+{{- end }}
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/cluster-total.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/cluster-total.yaml
|
||||
@@ -8,7 +8,7 @@
|
||||
@@ -4,11 +4,11 @@
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
@ -9,7 +14,7 @@
|
|||
name: {{ printf "%s-%s" (include "kube-prometheus-stack.fullname" $) "cluster-total" | trunc 63 | trimSuffix "-" }}
|
||||
annotations:
|
||||
{{ toYaml .Values.grafana.sidecar.dashboards.annotations | indent 4 }}
|
||||
@@ -1825,7 +1825,7 @@
|
||||
@@ -1825,14 +1825,14 @@
|
||||
"datasource": "$datasource",
|
||||
"hide": {{ if .Values.grafana.sidecar.dashboards.multicluster }}0{{ else }}2{{ end }},
|
||||
"includeAll": false,
|
||||
|
@ -18,6 +23,14 @@
|
|||
"multi": false,
|
||||
"name": "cluster",
|
||||
"options": [
|
||||
|
||||
],
|
||||
"query": "label_values(kube_pod_info, cluster)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"sort": 0,
|
||||
"tagValuesQuery": "",
|
||||
@@ -1879,4 +1879,4 @@
|
||||
"uid": "ff635a025bcfea7bc3dd4f508990a3e9",
|
||||
"version": 0
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled .Values.kubeControllerManager.enabled }}
|
||||
+{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if (include "exporter.kubeControllerManager.enabled" .)}}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
|
@ -21,9 +21,9 @@
|
|||
{
|
||||
- "expr": "sum(up{job=\"kube-controller-manager\"})",
|
||||
+ {{- if .Values.k3sServer.enabled }}
|
||||
+ "expr": "sum(up{job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\", metrics_path=\"/metrics\"})",
|
||||
+ "expr": "sum(up{cluster=\"$cluster\", job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\", metrics_path=\"/metrics\"})",
|
||||
+ {{- else }}
|
||||
+ "expr": "sum(up{job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\"})",
|
||||
+ "expr": "sum(up{cluster=\"$cluster\", job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\"})",
|
||||
+ {{- end }}
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
|
@ -33,7 +33,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "sum(rate(workqueue_adds_total{job=\"kube-controller-manager\", instance=~\"$instance\"}[5m])) by (instance, name)",
|
||||
+ "expr": "sum(rate(workqueue_adds_total{job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\", instance=~\"$instance\"}[5m])) by (instance, name)",
|
||||
+ "expr": "sum(rate(workqueue_adds_total{cluster=\"$cluster\", job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\", instance=~\"$instance\"}[5m])) by (instance, name)",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}} {{`{{`}}name{{`}}`}}",
|
||||
|
@ -42,7 +42,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "sum(rate(workqueue_depth{job=\"kube-controller-manager\", instance=~\"$instance\"}[5m])) by (instance, name)",
|
||||
+ "expr": "sum(rate(workqueue_depth{job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\", instance=~\"$instance\"}[5m])) by (instance, name)",
|
||||
+ "expr": "sum(rate(workqueue_depth{cluster=\"$cluster\", job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\", instance=~\"$instance\"}[5m])) by (instance, name)",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}} {{`{{`}}name{{`}}`}}",
|
||||
|
@ -51,7 +51,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "histogram_quantile(0.99, sum(rate(workqueue_queue_duration_seconds_bucket{job=\"kube-controller-manager\", instance=~\"$instance\"}[5m])) by (instance, name, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(workqueue_queue_duration_seconds_bucket{job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\", instance=~\"$instance\"}[5m])) by (instance, name, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(workqueue_queue_duration_seconds_bucket{cluster=\"$cluster\", job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\", instance=~\"$instance\"}[5m])) by (instance, name, le))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}} {{`{{`}}name{{`}}`}}",
|
||||
|
@ -93,7 +93,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "histogram_quantile(0.99, sum(rate(rest_client_request_duration_seconds_bucket{job=\"kube-controller-manager\", instance=~\"$instance\", verb=\"POST\"}[5m])) by (verb, url, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(rest_client_request_duration_seconds_bucket{job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\", instance=~\"$instance\", verb=\"POST\"}[5m])) by (verb, url, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(rest_client_request_duration_seconds_bucket{cluster=\"$cluster\", job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\", instance=~\"$instance\", verb=\"POST\"}[5m])) by (verb, url, le))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}verb{{`}}`}} {{`{{`}}url{{`}}`}}",
|
||||
|
@ -102,7 +102,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "histogram_quantile(0.99, sum(rate(rest_client_request_duration_seconds_bucket{job=\"kube-controller-manager\", instance=~\"$instance\", verb=\"GET\"}[5m])) by (verb, url, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(rest_client_request_duration_seconds_bucket{job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\", instance=~\"$instance\", verb=\"GET\"}[5m])) by (verb, url, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(rest_client_request_duration_seconds_bucket{cluster=\"$cluster\", job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\", instance=~\"$instance\", verb=\"GET\"}[5m])) by (verb, url, le))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}verb{{`}}`}} {{`{{`}}url{{`}}`}}",
|
||||
|
@ -111,7 +111,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "process_resident_memory_bytes{job=\"kube-controller-manager\",instance=~\"$instance\"}",
|
||||
+ "expr": "process_resident_memory_bytes{job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\",instance=~\"$instance\"}",
|
||||
+ "expr": "process_resident_memory_bytes{cluster=\"$cluster\", job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\",instance=~\"$instance\"}",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}}",
|
||||
|
@ -120,7 +120,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "rate(process_cpu_seconds_total{job=\"kube-controller-manager\",instance=~\"$instance\"}[5m])",
|
||||
+ "expr": "rate(process_cpu_seconds_total{job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\",instance=~\"$instance\"}[5m])",
|
||||
+ "expr": "rate(process_cpu_seconds_total{cluster=\"$cluster\", job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\",instance=~\"$instance\"}[5m])",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}}",
|
||||
|
@ -129,20 +129,53 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "go_goroutines{job=\"kube-controller-manager\",instance=~\"$instance\"}",
|
||||
+ "expr": "go_goroutines{job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\",instance=~\"$instance\"}",
|
||||
+ "expr": "go_goroutines{cluster=\"$cluster\", job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\",instance=~\"$instance\"}",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}}",
|
||||
@@ -1100,7 +1105,7 @@
|
||||
@@ -1092,6 +1097,32 @@
|
||||
|
||||
},
|
||||
"datasource": "$datasource",
|
||||
+ "hide": {{ if .Values.grafana.sidecar.dashboards.multicluster }}0{{ else }}2{{ end }},
|
||||
+ "includeAll": false,
|
||||
+ "label": "cluster",
|
||||
+ "multi": false,
|
||||
+ "name": "cluster",
|
||||
+ "options": [
|
||||
+
|
||||
+ ],
|
||||
+ "query": "label_values(kube_pod_info, cluster)",
|
||||
+ "refresh": 2,
|
||||
+ "regex": "",
|
||||
+ "sort": 1,
|
||||
+ "tagValuesQuery": "",
|
||||
+ "tags": [
|
||||
+
|
||||
+ ],
|
||||
+ "tagsQuery": "",
|
||||
+ "type": "query",
|
||||
+ "useTags": false
|
||||
+ },
|
||||
+ {
|
||||
+ "allValue": null,
|
||||
+ "current": {
|
||||
+
|
||||
+ },
|
||||
+ "datasource": "$datasource",
|
||||
"hide": 0,
|
||||
"includeAll": true,
|
||||
"label": null,
|
||||
@@ -1100,7 +1131,7 @@
|
||||
"options": [
|
||||
|
||||
],
|
||||
- "query": "label_values(process_cpu_seconds_total{job=\"kube-controller-manager\"}, instance)",
|
||||
+ "query": "label_values(process_cpu_seconds_total{job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\"}, instance)",
|
||||
+ "query": "label_values(process_cpu_seconds_total{cluster=\"$cluster\", job=\"{{ include "exporter.kubeControllerManager.jobName" . }}\"}, instance)",
|
||||
"refresh": 2,
|
||||
"regex": "",
|
||||
"sort": 1,
|
||||
@@ -1148,4 +1153,5 @@
|
||||
@@ -1148,4 +1179,5 @@
|
||||
"uid": "72e0e05bef5099e5f049b05fdc429ed4",
|
||||
"version": 0
|
||||
}
|
||||
|
|
|
@ -1,11 +1,15 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/etcd.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/etcd.yaml
|
||||
@@ -4,11 +4,12 @@
|
||||
@@ -1,14 +1,15 @@
|
||||
{{- /*
|
||||
-Generated from 'etcd' from https://raw.githubusercontent.com/etcd-io/website/master/content/docs/current/op-guide/grafana.json
|
||||
+Generated from 'etcd' from https://raw.githubusercontent.com/etcd-io/website/master/content/en/docs/v3.4/op-guide/grafana.json
|
||||
Do not change in-place! In order to change this file first read following link:
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled .Values.kubeEtcd.enabled }}
|
||||
+{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if (include "exporter.kubeEtcd.enabled" .)}}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
|
@ -15,10 +19,22 @@
|
|||
name: {{ printf "%s-%s" (include "kube-prometheus-stack.fullname" $) "etcd" | trunc 63 | trimSuffix "-" }}
|
||||
annotations:
|
||||
{{ toYaml .Values.grafana.sidecar.dashboards.annotations | indent 4 }}
|
||||
@@ -1113,4 +1114,5 @@
|
||||
"uid": "c2f4e12cdf69feb95caa41a5a1b423d9",
|
||||
@@ -28,6 +29,7 @@
|
||||
"editable": true,
|
||||
"gnetId": null,
|
||||
"hideControls": false,
|
||||
+ "id": 6,
|
||||
"links": [],
|
||||
"refresh": "10s",
|
||||
"rows": [
|
||||
@@ -1110,7 +1112,7 @@
|
||||
},
|
||||
"timezone": "browser",
|
||||
"title": "etcd",
|
||||
- "uid": "c2f4e12cdf69feb95caa41a5a1b423d9",
|
||||
"version": 215
|
||||
}
|
||||
+{{- end }}
|
||||
{{- end }}
|
||||
-{{- end }}
|
||||
\ No newline at end of file
|
||||
+{{- end }}
|
||||
+{{- end }}
|
||||
|
|
|
@ -1,6 +1,10 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/k8s-coredns.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/k8s-coredns.yaml
|
||||
@@ -4,10 +4,8 @@
|
||||
@@ -1,13 +1,11 @@
|
||||
{{- /* Added manually, can be changed in-place. */ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled .Values.coreDns.enabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled .Values.coreDns.enabled }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/k8s-resources-cluster.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/k8s-resources-cluster.yaml
|
||||
@@ -8,7 +8,7 @@
|
||||
@@ -4,11 +4,11 @@
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
@ -9,3 +14,825 @@
|
|||
name: {{ printf "%s-%s" (include "kube-prometheus-stack.fullname" $) "k8s-resources-cluster" | trunc 63 | trimSuffix "-" }}
|
||||
annotations:
|
||||
{{ toYaml .Values.grafana.sidecar.dashboards.annotations | indent 4 }}
|
||||
@@ -163,7 +163,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "sum(kube_pod_container_resource_requests_cpu_cores{cluster=\"$cluster\"}) / sum(kube_node_status_allocatable_cpu_cores{cluster=\"$cluster\"})",
|
||||
+ "expr": "sum(namespace_cpu:kube_pod_container_resource_requests:sum{cluster=\"$cluster\"}) / sum(kube_node_status_allocatable{resource=\"cpu\",cluster=\"$cluster\"})",
|
||||
"format": "time_series",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -247,7 +247,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "sum(kube_pod_container_resource_limits_cpu_cores{cluster=\"$cluster\"}) / sum(kube_node_status_allocatable_cpu_cores{cluster=\"$cluster\"})",
|
||||
+ "expr": "sum(kube_pod_container_resource_limits{cluster=\"$cluster\", resource=\"cpu\"}) / sum(kube_node_status_allocatable{resource=\"cpu\",cluster=\"$cluster\"})",
|
||||
"format": "time_series",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -331,7 +331,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "1 - sum(:node_memory_MemAvailable_bytes:sum{cluster=\"$cluster\"}) / sum(kube_node_status_allocatable_memory_bytes{cluster=\"$cluster\"})",
|
||||
+ "expr": "1 - sum(:node_memory_MemAvailable_bytes:sum{cluster=\"$cluster\"}) / sum(node_memory_MemTotal_bytes{cluster=\"$cluster\"})",
|
||||
"format": "time_series",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -415,7 +415,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "sum(kube_pod_container_resource_requests_memory_bytes{cluster=\"$cluster\"}) / sum(kube_node_status_allocatable_memory_bytes{cluster=\"$cluster\"})",
|
||||
+ "expr": "sum(namespace_memory:kube_pod_container_resource_requests:sum{cluster=\"$cluster\"}) / sum(kube_node_status_allocatable{resource=\"memory\",cluster=\"$cluster\"})",
|
||||
"format": "time_series",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -499,7 +499,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "sum(kube_pod_container_resource_limits_memory_bytes{cluster=\"$cluster\"}) / sum(kube_node_status_allocatable_memory_bytes{cluster=\"$cluster\"})",
|
||||
+ "expr": "sum(kube_pod_container_resource_limits{cluster=\"$cluster\", resource=\"memory\"}) / sum(kube_node_status_allocatable{resource=\"memory\",cluster=\"$cluster\"})",
|
||||
"format": "time_series",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -894,7 +894,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(kube_pod_container_resource_requests_cpu_cores{cluster=\"$cluster\"}) by (namespace)",
|
||||
+ "expr": "sum(namespace_cpu:kube_pod_container_resource_requests:sum{cluster=\"$cluster\"}) by (namespace)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -903,7 +903,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\"}) by (namespace) / sum(kube_pod_container_resource_requests_cpu_cores{cluster=\"$cluster\"}) by (namespace)",
|
||||
+ "expr": "sum(node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\"}) by (namespace) / sum(kube_pod_container_resource_requests{cluster=\"$cluster\", resource=\"cpu\"}) by (namespace)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -912,7 +912,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(kube_pod_container_resource_limits_cpu_cores{cluster=\"$cluster\"}) by (namespace)",
|
||||
+ "expr": "sum(kube_pod_container_resource_limits{cluster=\"$cluster\", resource=\"cpu\"}) by (namespace)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -921,7 +921,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\"}) by (namespace) / sum(kube_pod_container_resource_limits_cpu_cores{cluster=\"$cluster\"}) by (namespace)",
|
||||
+ "expr": "sum(node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\"}) by (namespace) / sum(kube_pod_container_resource_limits{cluster=\"$cluster\", resource=\"cpu\"}) by (namespace)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -1321,7 +1321,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(kube_pod_container_resource_requests_memory_bytes{cluster=\"$cluster\"}) by (namespace)",
|
||||
+ "expr": "sum(kube_pod_container_resource_requests{cluster=\"$cluster\", resource=\"memory\"}) by (namespace)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -1330,7 +1330,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(container_memory_rss{cluster=\"$cluster\", container!=\"\"}) by (namespace) / sum(kube_pod_container_resource_requests_memory_bytes{cluster=\"$cluster\"}) by (namespace)",
|
||||
+ "expr": "sum(container_memory_rss{cluster=\"$cluster\", container!=\"\"}) by (namespace) / sum(kube_pod_container_resource_requests{cluster=\"$cluster\", resource=\"memory\"}) by (namespace)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -1339,7 +1339,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(kube_pod_container_resource_limits_memory_bytes{cluster=\"$cluster\"}) by (namespace)",
|
||||
+ "expr": "sum(kube_pod_container_resource_limits{cluster=\"$cluster\", resource=\"memory\"}) by (namespace)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -1348,7 +1348,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(container_memory_rss{cluster=\"$cluster\", container!=\"\"}) by (namespace) / sum(kube_pod_container_resource_limits_memory_bytes{cluster=\"$cluster\"}) by (namespace)",
|
||||
+ "expr": "sum(container_memory_rss{cluster=\"$cluster\", container!=\"\"}) by (namespace) / sum(kube_pod_container_resource_limits{cluster=\"$cluster\", resource=\"memory\"}) by (namespace)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -1705,7 +1705,7 @@
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Current Network Usage",
|
||||
"titleSize": "h6"
|
||||
},
|
||||
{
|
||||
@@ -1745,7 +1745,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1797,19 +1797,7 @@
|
||||
"show": false
|
||||
}
|
||||
]
|
||||
- }
|
||||
- ],
|
||||
- "repeat": null,
|
||||
- "repeatIteration": null,
|
||||
- "repeatRowId": null,
|
||||
- "showTitle": true,
|
||||
- "title": "Network",
|
||||
- "titleSize": "h6"
|
||||
- },
|
||||
- {
|
||||
- "collapse": false,
|
||||
- "height": "250px",
|
||||
- "panels": [
|
||||
+ },
|
||||
{
|
||||
"aliasColors": {
|
||||
|
||||
@@ -1843,7 +1831,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1901,7 +1889,7 @@
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Bandwidth",
|
||||
"titleSize": "h6"
|
||||
},
|
||||
{
|
||||
@@ -1941,7 +1929,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1993,19 +1981,7 @@
|
||||
"show": false
|
||||
}
|
||||
]
|
||||
- }
|
||||
- ],
|
||||
- "repeat": null,
|
||||
- "repeatIteration": null,
|
||||
- "repeatRowId": null,
|
||||
- "showTitle": true,
|
||||
- "title": "Network",
|
||||
- "titleSize": "h6"
|
||||
- },
|
||||
- {
|
||||
- "collapse": false,
|
||||
- "height": "250px",
|
||||
- "panels": [
|
||||
+ },
|
||||
{
|
||||
"aliasColors": {
|
||||
|
||||
@@ -2039,7 +2015,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -2097,7 +2073,7 @@
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Average Container Bandwidth by Namespace",
|
||||
"titleSize": "h6"
|
||||
},
|
||||
{
|
||||
@@ -2137,7 +2113,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -2189,19 +2165,7 @@
|
||||
"show": false
|
||||
}
|
||||
]
|
||||
- }
|
||||
- ],
|
||||
- "repeat": null,
|
||||
- "repeatIteration": null,
|
||||
- "repeatRowId": null,
|
||||
- "showTitle": true,
|
||||
- "title": "Network",
|
||||
- "titleSize": "h6"
|
||||
- },
|
||||
- {
|
||||
- "collapse": false,
|
||||
- "height": "250px",
|
||||
- "panels": [
|
||||
+ },
|
||||
{
|
||||
"aliasColors": {
|
||||
|
||||
@@ -2235,7 +2199,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -2293,7 +2257,7 @@
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Rate of Packets",
|
||||
"titleSize": "h6"
|
||||
},
|
||||
{
|
||||
@@ -2333,7 +2297,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -2385,13 +2349,99 @@
|
||||
"show": false
|
||||
}
|
||||
]
|
||||
+ },
|
||||
+ {
|
||||
+ "aliasColors": {
|
||||
+
|
||||
+ },
|
||||
+ "bars": false,
|
||||
+ "dashLength": 10,
|
||||
+ "dashes": false,
|
||||
+ "datasource": "$datasource",
|
||||
+ "fill": 10,
|
||||
+ "id": 19,
|
||||
+ "legend": {
|
||||
+ "avg": false,
|
||||
+ "current": false,
|
||||
+ "max": false,
|
||||
+ "min": false,
|
||||
+ "show": true,
|
||||
+ "total": false,
|
||||
+ "values": false
|
||||
+ },
|
||||
+ "lines": true,
|
||||
+ "linewidth": 0,
|
||||
+ "links": [
|
||||
+
|
||||
+ ],
|
||||
+ "nullPointMode": "null as zero",
|
||||
+ "percentage": false,
|
||||
+ "pointradius": 5,
|
||||
+ "points": false,
|
||||
+ "renderer": "flot",
|
||||
+ "seriesOverrides": [
|
||||
+
|
||||
+ ],
|
||||
+ "spaceLength": 10,
|
||||
+ "span": 6,
|
||||
+ "stack": true,
|
||||
+ "steppedLine": false,
|
||||
+ "targets": [
|
||||
+ {
|
||||
+ "expr": "sum(irate(container_network_transmit_packets_dropped_total{cluster=\"$cluster\", namespace=~\".+\"}[$__rate_interval])) by (namespace)",
|
||||
+ "format": "time_series",
|
||||
+ "intervalFactor": 2,
|
||||
+ "legendFormat": "{{`{{`}}namespace{{`}}`}}",
|
||||
+ "legendLink": null,
|
||||
+ "step": 10
|
||||
+ }
|
||||
+ ],
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "timeFrom": null,
|
||||
+ "timeShift": null,
|
||||
+ "title": "Rate of Transmitted Packets Dropped",
|
||||
+ "tooltip": {
|
||||
+ "shared": false,
|
||||
+ "sort": 0,
|
||||
+ "value_type": "individual"
|
||||
+ },
|
||||
+ "type": "graph",
|
||||
+ "xaxis": {
|
||||
+ "buckets": null,
|
||||
+ "mode": "time",
|
||||
+ "name": null,
|
||||
+ "show": true,
|
||||
+ "values": [
|
||||
+
|
||||
+ ]
|
||||
+ },
|
||||
+ "yaxes": [
|
||||
+ {
|
||||
+ "format": "Bps",
|
||||
+ "label": null,
|
||||
+ "logBase": 1,
|
||||
+ "max": null,
|
||||
+ "min": 0,
|
||||
+ "show": true
|
||||
+ },
|
||||
+ {
|
||||
+ "format": "short",
|
||||
+ "label": null,
|
||||
+ "logBase": 1,
|
||||
+ "max": null,
|
||||
+ "min": null,
|
||||
+ "show": false
|
||||
+ }
|
||||
+ ]
|
||||
}
|
||||
],
|
||||
"repeat": null,
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Rate of Packets Dropped",
|
||||
"titleSize": "h6"
|
||||
},
|
||||
{
|
||||
@@ -2406,8 +2456,9 @@
|
||||
"dashLength": 10,
|
||||
"dashes": false,
|
||||
"datasource": "$datasource",
|
||||
+ "decimals": -1,
|
||||
"fill": 10,
|
||||
- "id": 19,
|
||||
+ "id": 20,
|
||||
"legend": {
|
||||
"avg": false,
|
||||
"current": false,
|
||||
@@ -2431,12 +2482,12 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "sum(irate(container_network_transmit_packets_dropped_total{cluster=\"$cluster\", namespace=~\".+\"}[$__rate_interval])) by (namespace)",
|
||||
+ "expr": "ceil(sum by(namespace) (rate(container_fs_reads_total{container!=\"\", cluster=\"$cluster\"}[5m]) + rate(container_fs_writes_total{container!=\"\", cluster=\"$cluster\"}[5m])))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}namespace{{`}}`}}",
|
||||
@@ -2449,7 +2500,93 @@
|
||||
],
|
||||
"timeFrom": null,
|
||||
"timeShift": null,
|
||||
- "title": "Rate of Transmitted Packets Dropped",
|
||||
+ "title": "IOPS(Reads+Writes)",
|
||||
+ "tooltip": {
|
||||
+ "shared": false,
|
||||
+ "sort": 0,
|
||||
+ "value_type": "individual"
|
||||
+ },
|
||||
+ "type": "graph",
|
||||
+ "xaxis": {
|
||||
+ "buckets": null,
|
||||
+ "mode": "time",
|
||||
+ "name": null,
|
||||
+ "show": true,
|
||||
+ "values": [
|
||||
+
|
||||
+ ]
|
||||
+ },
|
||||
+ "yaxes": [
|
||||
+ {
|
||||
+ "format": "short",
|
||||
+ "label": null,
|
||||
+ "logBase": 1,
|
||||
+ "max": null,
|
||||
+ "min": 0,
|
||||
+ "show": true
|
||||
+ },
|
||||
+ {
|
||||
+ "format": "short",
|
||||
+ "label": null,
|
||||
+ "logBase": 1,
|
||||
+ "max": null,
|
||||
+ "min": null,
|
||||
+ "show": false
|
||||
+ }
|
||||
+ ]
|
||||
+ },
|
||||
+ {
|
||||
+ "aliasColors": {
|
||||
+
|
||||
+ },
|
||||
+ "bars": false,
|
||||
+ "dashLength": 10,
|
||||
+ "dashes": false,
|
||||
+ "datasource": "$datasource",
|
||||
+ "fill": 10,
|
||||
+ "id": 21,
|
||||
+ "legend": {
|
||||
+ "avg": false,
|
||||
+ "current": false,
|
||||
+ "max": false,
|
||||
+ "min": false,
|
||||
+ "show": true,
|
||||
+ "total": false,
|
||||
+ "values": false
|
||||
+ },
|
||||
+ "lines": true,
|
||||
+ "linewidth": 0,
|
||||
+ "links": [
|
||||
+
|
||||
+ ],
|
||||
+ "nullPointMode": "null as zero",
|
||||
+ "percentage": false,
|
||||
+ "pointradius": 5,
|
||||
+ "points": false,
|
||||
+ "renderer": "flot",
|
||||
+ "seriesOverrides": [
|
||||
+
|
||||
+ ],
|
||||
+ "spaceLength": 10,
|
||||
+ "span": 6,
|
||||
+ "stack": true,
|
||||
+ "steppedLine": false,
|
||||
+ "targets": [
|
||||
+ {
|
||||
+ "expr": "sum by(namespace) (rate(container_fs_reads_bytes_total{container!=\"\", cluster=\"$cluster\"}[5m]) + rate(container_fs_writes_bytes_total{container!=\"\", cluster=\"$cluster\"}[5m]))",
|
||||
+ "format": "time_series",
|
||||
+ "intervalFactor": 2,
|
||||
+ "legendFormat": "{{`{{`}}namespace{{`}}`}}",
|
||||
+ "legendLink": null,
|
||||
+ "step": 10
|
||||
+ }
|
||||
+ ],
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "timeFrom": null,
|
||||
+ "timeShift": null,
|
||||
+ "title": "ThroughPut(Read+Write)",
|
||||
"tooltip": {
|
||||
"shared": false,
|
||||
"sort": 0,
|
||||
@@ -2489,7 +2626,312 @@
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Storage IO",
|
||||
+ "titleSize": "h6"
|
||||
+ },
|
||||
+ {
|
||||
+ "collapse": false,
|
||||
+ "height": "250px",
|
||||
+ "panels": [
|
||||
+ {
|
||||
+ "aliasColors": {
|
||||
+
|
||||
+ },
|
||||
+ "bars": false,
|
||||
+ "dashLength": 10,
|
||||
+ "dashes": false,
|
||||
+ "datasource": "$datasource",
|
||||
+ "fill": 1,
|
||||
+ "id": 22,
|
||||
+ "legend": {
|
||||
+ "avg": false,
|
||||
+ "current": false,
|
||||
+ "max": false,
|
||||
+ "min": false,
|
||||
+ "show": true,
|
||||
+ "total": false,
|
||||
+ "values": false
|
||||
+ },
|
||||
+ "lines": true,
|
||||
+ "linewidth": 1,
|
||||
+ "links": [
|
||||
+
|
||||
+ ],
|
||||
+ "nullPointMode": "null as zero",
|
||||
+ "percentage": false,
|
||||
+ "pointradius": 5,
|
||||
+ "points": false,
|
||||
+ "renderer": "flot",
|
||||
+ "seriesOverrides": [
|
||||
+
|
||||
+ ],
|
||||
+ "sort": {
|
||||
+ "col": 4,
|
||||
+ "desc": true
|
||||
+ },
|
||||
+ "spaceLength": 10,
|
||||
+ "span": 12,
|
||||
+ "stack": false,
|
||||
+ "steppedLine": false,
|
||||
+ "styles": [
|
||||
+ {
|
||||
+ "alias": "Time",
|
||||
+ "dateFormat": "YYYY-MM-DD HH:mm:ss",
|
||||
+ "pattern": "Time",
|
||||
+ "type": "hidden"
|
||||
+ },
|
||||
+ {
|
||||
+ "alias": "IOPS(Reads)",
|
||||
+ "colorMode": null,
|
||||
+ "colors": [
|
||||
+
|
||||
+ ],
|
||||
+ "dateFormat": "YYYY-MM-DD HH:mm:ss",
|
||||
+ "decimals": -1,
|
||||
+ "link": false,
|
||||
+ "linkTargetBlank": false,
|
||||
+ "linkTooltip": "Drill down",
|
||||
+ "linkUrl": "",
|
||||
+ "pattern": "Value #A",
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "type": "number",
|
||||
+ "unit": "short"
|
||||
+ },
|
||||
+ {
|
||||
+ "alias": "IOPS(Writes)",
|
||||
+ "colorMode": null,
|
||||
+ "colors": [
|
||||
+
|
||||
+ ],
|
||||
+ "dateFormat": "YYYY-MM-DD HH:mm:ss",
|
||||
+ "decimals": -1,
|
||||
+ "link": false,
|
||||
+ "linkTargetBlank": false,
|
||||
+ "linkTooltip": "Drill down",
|
||||
+ "linkUrl": "",
|
||||
+ "pattern": "Value #B",
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "type": "number",
|
||||
+ "unit": "short"
|
||||
+ },
|
||||
+ {
|
||||
+ "alias": "IOPS(Reads + Writes)",
|
||||
+ "colorMode": null,
|
||||
+ "colors": [
|
||||
+
|
||||
+ ],
|
||||
+ "dateFormat": "YYYY-MM-DD HH:mm:ss",
|
||||
+ "decimals": -1,
|
||||
+ "link": false,
|
||||
+ "linkTargetBlank": false,
|
||||
+ "linkTooltip": "Drill down",
|
||||
+ "linkUrl": "",
|
||||
+ "pattern": "Value #C",
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "type": "number",
|
||||
+ "unit": "short"
|
||||
+ },
|
||||
+ {
|
||||
+ "alias": "Throughput(Read)",
|
||||
+ "colorMode": null,
|
||||
+ "colors": [
|
||||
+
|
||||
+ ],
|
||||
+ "dateFormat": "YYYY-MM-DD HH:mm:ss",
|
||||
+ "decimals": 2,
|
||||
+ "link": false,
|
||||
+ "linkTargetBlank": false,
|
||||
+ "linkTooltip": "Drill down",
|
||||
+ "linkUrl": "",
|
||||
+ "pattern": "Value #D",
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "type": "number",
|
||||
+ "unit": "Bps"
|
||||
+ },
|
||||
+ {
|
||||
+ "alias": "Throughput(Write)",
|
||||
+ "colorMode": null,
|
||||
+ "colors": [
|
||||
+
|
||||
+ ],
|
||||
+ "dateFormat": "YYYY-MM-DD HH:mm:ss",
|
||||
+ "decimals": 2,
|
||||
+ "link": false,
|
||||
+ "linkTargetBlank": false,
|
||||
+ "linkTooltip": "Drill down",
|
||||
+ "linkUrl": "",
|
||||
+ "pattern": "Value #E",
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "type": "number",
|
||||
+ "unit": "Bps"
|
||||
+ },
|
||||
+ {
|
||||
+ "alias": "Throughput(Read + Write)",
|
||||
+ "colorMode": null,
|
||||
+ "colors": [
|
||||
+
|
||||
+ ],
|
||||
+ "dateFormat": "YYYY-MM-DD HH:mm:ss",
|
||||
+ "decimals": 2,
|
||||
+ "link": false,
|
||||
+ "linkTargetBlank": false,
|
||||
+ "linkTooltip": "Drill down",
|
||||
+ "linkUrl": "",
|
||||
+ "pattern": "Value #F",
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "type": "number",
|
||||
+ "unit": "Bps"
|
||||
+ },
|
||||
+ {
|
||||
+ "alias": "Namespace",
|
||||
+ "colorMode": null,
|
||||
+ "colors": [
|
||||
+
|
||||
+ ],
|
||||
+ "dateFormat": "YYYY-MM-DD HH:mm:ss",
|
||||
+ "decimals": 2,
|
||||
+ "link": true,
|
||||
+ "linkTargetBlank": false,
|
||||
+ "linkTooltip": "Drill down to pods",
|
||||
+ "linkUrl": "./d/85a562078cdf77779eaa1add43ccec1e/k8s-resources-namespace?var-datasource=$datasource&var-cluster=$cluster&var-namespace=$__cell",
|
||||
+ "pattern": "namespace",
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "type": "number",
|
||||
+ "unit": "short"
|
||||
+ },
|
||||
+ {
|
||||
+ "alias": "",
|
||||
+ "colorMode": null,
|
||||
+ "colors": [
|
||||
+
|
||||
+ ],
|
||||
+ "dateFormat": "YYYY-MM-DD HH:mm:ss",
|
||||
+ "decimals": 2,
|
||||
+ "pattern": "/.*/",
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "type": "string",
|
||||
+ "unit": "short"
|
||||
+ }
|
||||
+ ],
|
||||
+ "targets": [
|
||||
+ {
|
||||
+ "expr": "sum by(namespace) (rate(container_fs_reads_total{container!=\"\", cluster=\"$cluster\"}[5m]))",
|
||||
+ "format": "table",
|
||||
+ "instant": true,
|
||||
+ "intervalFactor": 2,
|
||||
+ "legendFormat": "",
|
||||
+ "refId": "A",
|
||||
+ "step": 10
|
||||
+ },
|
||||
+ {
|
||||
+ "expr": "sum by(namespace) (rate(container_fs_writes_total{container!=\"\", cluster=\"$cluster\"}[5m]))",
|
||||
+ "format": "table",
|
||||
+ "instant": true,
|
||||
+ "intervalFactor": 2,
|
||||
+ "legendFormat": "",
|
||||
+ "refId": "B",
|
||||
+ "step": 10
|
||||
+ },
|
||||
+ {
|
||||
+ "expr": "sum by(namespace) (rate(container_fs_reads_total{container!=\"\", cluster=\"$cluster\"}[5m]) + rate(container_fs_writes_total{container!=\"\", cluster=\"$cluster\"}[5m]))",
|
||||
+ "format": "table",
|
||||
+ "instant": true,
|
||||
+ "intervalFactor": 2,
|
||||
+ "legendFormat": "",
|
||||
+ "refId": "C",
|
||||
+ "step": 10
|
||||
+ },
|
||||
+ {
|
||||
+ "expr": "sum by(namespace) (rate(container_fs_reads_bytes_total{container!=\"\", cluster=\"$cluster\"}[5m]))",
|
||||
+ "format": "table",
|
||||
+ "instant": true,
|
||||
+ "intervalFactor": 2,
|
||||
+ "legendFormat": "",
|
||||
+ "refId": "D",
|
||||
+ "step": 10
|
||||
+ },
|
||||
+ {
|
||||
+ "expr": "sum by(namespace) (rate(container_fs_writes_bytes_total{container!=\"\", cluster=\"$cluster\"}[5m]))",
|
||||
+ "format": "table",
|
||||
+ "instant": true,
|
||||
+ "intervalFactor": 2,
|
||||
+ "legendFormat": "",
|
||||
+ "refId": "E",
|
||||
+ "step": 10
|
||||
+ },
|
||||
+ {
|
||||
+ "expr": "sum by(namespace) (rate(container_fs_reads_bytes_total{container!=\"\", cluster=\"$cluster\"}[5m]) + rate(container_fs_writes_bytes_total{container!=\"\", cluster=\"$cluster\"}[5m]))",
|
||||
+ "format": "table",
|
||||
+ "instant": true,
|
||||
+ "intervalFactor": 2,
|
||||
+ "legendFormat": "",
|
||||
+ "refId": "F",
|
||||
+ "step": 10
|
||||
+ }
|
||||
+ ],
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "timeFrom": null,
|
||||
+ "timeShift": null,
|
||||
+ "title": "Current Storage IO",
|
||||
+ "tooltip": {
|
||||
+ "shared": false,
|
||||
+ "sort": 0,
|
||||
+ "value_type": "individual"
|
||||
+ },
|
||||
+ "transform": "table",
|
||||
+ "type": "table",
|
||||
+ "xaxis": {
|
||||
+ "buckets": null,
|
||||
+ "mode": "time",
|
||||
+ "name": null,
|
||||
+ "show": true,
|
||||
+ "values": [
|
||||
+
|
||||
+ ]
|
||||
+ },
|
||||
+ "yaxes": [
|
||||
+ {
|
||||
+ "format": "short",
|
||||
+ "label": null,
|
||||
+ "logBase": 1,
|
||||
+ "max": null,
|
||||
+ "min": 0,
|
||||
+ "show": true
|
||||
+ },
|
||||
+ {
|
||||
+ "format": "short",
|
||||
+ "label": null,
|
||||
+ "logBase": 1,
|
||||
+ "max": null,
|
||||
+ "min": null,
|
||||
+ "show": false
|
||||
+ }
|
||||
+ ]
|
||||
+ }
|
||||
+ ],
|
||||
+ "repeat": null,
|
||||
+ "repeatIteration": null,
|
||||
+ "repeatRowId": null,
|
||||
+ "showTitle": true,
|
||||
+ "title": "Storage IO - Distribution",
|
||||
"titleSize": "h6"
|
||||
}
|
||||
],
|
||||
@@ -2579,4 +3021,4 @@
|
||||
"uid": "efa86fd1d0c121a26444b636a3f509a8",
|
||||
"version": 0
|
||||
}
|
||||
-{{- end }}
|
||||
\ No newline at end of file
|
||||
+{{- end }}
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/k8s-resources-namespace.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/k8s-resources-namespace.yaml
|
||||
@@ -8,7 +8,7 @@
|
||||
@@ -4,11 +4,11 @@
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
@ -9,3 +14,839 @@
|
|||
name: {{ printf "%s-%s" (include "kube-prometheus-stack.fullname" $) "k8s-resources-namespace" | trunc 63 | trimSuffix "-" }}
|
||||
annotations:
|
||||
{{ toYaml .Values.grafana.sidecar.dashboards.annotations | indent 4 }}
|
||||
@@ -78,7 +78,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "sum(node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", namespace=\"$namespace\"}) / sum(kube_pod_container_resource_requests_cpu_cores{cluster=\"$cluster\", namespace=\"$namespace\"})",
|
||||
+ "expr": "sum(node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", namespace=\"$namespace\"}) / sum(kube_pod_container_resource_requests{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"cpu\"})",
|
||||
"format": "time_series",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -162,7 +162,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "sum(node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", namespace=\"$namespace\"}) / sum(kube_pod_container_resource_limits_cpu_cores{cluster=\"$cluster\", namespace=\"$namespace\"})",
|
||||
+ "expr": "sum(node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", namespace=\"$namespace\"}) / sum(kube_pod_container_resource_limits{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"cpu\"})",
|
||||
"format": "time_series",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -246,7 +246,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "sum(container_memory_working_set_bytes{cluster=\"$cluster\", namespace=\"$namespace\",container!=\"\", image!=\"\"}) / sum(kube_pod_container_resource_requests_memory_bytes{namespace=\"$namespace\"})",
|
||||
+ "expr": "sum(container_memory_working_set_bytes{cluster=\"$cluster\", namespace=\"$namespace\",container!=\"\", image!=\"\"}) / sum(kube_pod_container_resource_requests{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"memory\"})",
|
||||
"format": "time_series",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -256,7 +256,7 @@
|
||||
"thresholds": "70,80",
|
||||
"timeFrom": null,
|
||||
"timeShift": null,
|
||||
- "title": "Memory Utilization (from requests)",
|
||||
+ "title": "Memory Utilisation (from requests)",
|
||||
"tooltip": {
|
||||
"shared": false,
|
||||
"sort": 0,
|
||||
@@ -330,7 +330,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "sum(container_memory_working_set_bytes{cluster=\"$cluster\", namespace=\"$namespace\",container!=\"\", image!=\"\"}) / sum(kube_pod_container_resource_limits_memory_bytes{namespace=\"$namespace\"})",
|
||||
+ "expr": "sum(container_memory_working_set_bytes{cluster=\"$cluster\", namespace=\"$namespace\",container!=\"\", image!=\"\"}) / sum(kube_pod_container_resource_limits{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"memory\"})",
|
||||
"format": "time_series",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -422,8 +422,9 @@
|
||||
"color": "#F2495C",
|
||||
"dashes": true,
|
||||
"fill": 0,
|
||||
+ "hiddenSeries": true,
|
||||
"hideTooltip": true,
|
||||
- "legend": false,
|
||||
+ "legend": true,
|
||||
"linewidth": 2,
|
||||
"stack": false
|
||||
},
|
||||
@@ -432,8 +433,9 @@
|
||||
"color": "#FF9830",
|
||||
"dashes": true,
|
||||
"fill": 0,
|
||||
+ "hiddenSeries": true,
|
||||
"hideTooltip": true,
|
||||
- "legend": false,
|
||||
+ "legend": true,
|
||||
"linewidth": 2,
|
||||
"stack": false
|
||||
}
|
||||
@@ -704,7 +706,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(kube_pod_container_resource_requests_cpu_cores{cluster=\"$cluster\", namespace=\"$namespace\"}) by (pod)",
|
||||
+ "expr": "sum(kube_pod_container_resource_requests{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"cpu\"}) by (pod)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -713,7 +715,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", namespace=\"$namespace\"}) by (pod) / sum(kube_pod_container_resource_requests_cpu_cores{cluster=\"$cluster\", namespace=\"$namespace\"}) by (pod)",
|
||||
+ "expr": "sum(node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", namespace=\"$namespace\"}) by (pod) / sum(kube_pod_container_resource_requests{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"cpu\"}) by (pod)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -722,7 +724,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(kube_pod_container_resource_limits_cpu_cores{cluster=\"$cluster\", namespace=\"$namespace\"}) by (pod)",
|
||||
+ "expr": "sum(kube_pod_container_resource_limits{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"cpu\"}) by (pod)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -731,7 +733,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", namespace=\"$namespace\"}) by (pod) / sum(kube_pod_container_resource_limits_cpu_cores{cluster=\"$cluster\", namespace=\"$namespace\"}) by (pod)",
|
||||
+ "expr": "sum(node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", namespace=\"$namespace\"}) by (pod) / sum(kube_pod_container_resource_limits{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"cpu\"}) by (pod)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -828,8 +830,9 @@
|
||||
"color": "#F2495C",
|
||||
"dashes": true,
|
||||
"fill": 0,
|
||||
+ "hiddenSeries": true,
|
||||
"hideTooltip": true,
|
||||
- "legend": false,
|
||||
+ "legend": true,
|
||||
"linewidth": 2,
|
||||
"stack": false
|
||||
},
|
||||
@@ -838,8 +841,9 @@
|
||||
"color": "#FF9830",
|
||||
"dashes": true,
|
||||
"fill": 0,
|
||||
+ "hiddenSeries": true,
|
||||
"hideTooltip": true,
|
||||
- "legend": false,
|
||||
+ "legend": true,
|
||||
"linewidth": 2,
|
||||
"stack": false
|
||||
}
|
||||
@@ -1167,7 +1171,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(kube_pod_container_resource_requests_memory_bytes{cluster=\"$cluster\", namespace=\"$namespace\"}) by (pod)",
|
||||
+ "expr": "sum(kube_pod_container_resource_requests{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"memory\"}) by (pod)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -1176,7 +1180,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(container_memory_working_set_bytes{cluster=\"$cluster\", namespace=\"$namespace\",container!=\"\", image!=\"\"}) by (pod) / sum(kube_pod_container_resource_requests_memory_bytes{namespace=\"$namespace\"}) by (pod)",
|
||||
+ "expr": "sum(container_memory_working_set_bytes{cluster=\"$cluster\", namespace=\"$namespace\",container!=\"\", image!=\"\"}) by (pod) / sum(kube_pod_container_resource_requests{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"memory\"}) by (pod)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -1185,7 +1189,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(kube_pod_container_resource_limits_memory_bytes{cluster=\"$cluster\", namespace=\"$namespace\"}) by (pod)",
|
||||
+ "expr": "sum(kube_pod_container_resource_limits{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"memory\"}) by (pod)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -1194,7 +1198,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(container_memory_working_set_bytes{cluster=\"$cluster\", namespace=\"$namespace\",container!=\"\", image!=\"\"}) by (pod) / sum(kube_pod_container_resource_limits_memory_bytes{namespace=\"$namespace\"}) by (pod)",
|
||||
+ "expr": "sum(container_memory_working_set_bytes{cluster=\"$cluster\", namespace=\"$namespace\",container!=\"\", image!=\"\"}) by (pod) / sum(kube_pod_container_resource_limits{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"memory\"}) by (pod)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -1578,7 +1582,7 @@
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Current Network Usage",
|
||||
"titleSize": "h6"
|
||||
},
|
||||
{
|
||||
@@ -1618,7 +1622,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1670,19 +1674,7 @@
|
||||
"show": false
|
||||
}
|
||||
]
|
||||
- }
|
||||
- ],
|
||||
- "repeat": null,
|
||||
- "repeatIteration": null,
|
||||
- "repeatRowId": null,
|
||||
- "showTitle": true,
|
||||
- "title": "Network",
|
||||
- "titleSize": "h6"
|
||||
- },
|
||||
- {
|
||||
- "collapse": false,
|
||||
- "height": "250px",
|
||||
- "panels": [
|
||||
+ },
|
||||
{
|
||||
"aliasColors": {
|
||||
|
||||
@@ -1716,7 +1708,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1774,7 +1766,7 @@
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Bandwidth",
|
||||
"titleSize": "h6"
|
||||
},
|
||||
{
|
||||
@@ -1814,7 +1806,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1866,19 +1858,7 @@
|
||||
"show": false
|
||||
}
|
||||
]
|
||||
- }
|
||||
- ],
|
||||
- "repeat": null,
|
||||
- "repeatIteration": null,
|
||||
- "repeatRowId": null,
|
||||
- "showTitle": true,
|
||||
- "title": "Network",
|
||||
- "titleSize": "h6"
|
||||
- },
|
||||
- {
|
||||
- "collapse": false,
|
||||
- "height": "250px",
|
||||
- "panels": [
|
||||
+ },
|
||||
{
|
||||
"aliasColors": {
|
||||
|
||||
@@ -1912,7 +1892,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1970,7 +1950,7 @@
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Rate of Packets",
|
||||
"titleSize": "h6"
|
||||
},
|
||||
{
|
||||
@@ -2010,7 +1990,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -2062,13 +2042,99 @@
|
||||
"show": false
|
||||
}
|
||||
]
|
||||
+ },
|
||||
+ {
|
||||
+ "aliasColors": {
|
||||
+
|
||||
+ },
|
||||
+ "bars": false,
|
||||
+ "dashLength": 10,
|
||||
+ "dashes": false,
|
||||
+ "datasource": "$datasource",
|
||||
+ "fill": 10,
|
||||
+ "id": 15,
|
||||
+ "legend": {
|
||||
+ "avg": false,
|
||||
+ "current": false,
|
||||
+ "max": false,
|
||||
+ "min": false,
|
||||
+ "show": true,
|
||||
+ "total": false,
|
||||
+ "values": false
|
||||
+ },
|
||||
+ "lines": true,
|
||||
+ "linewidth": 0,
|
||||
+ "links": [
|
||||
+
|
||||
+ ],
|
||||
+ "nullPointMode": "null as zero",
|
||||
+ "percentage": false,
|
||||
+ "pointradius": 5,
|
||||
+ "points": false,
|
||||
+ "renderer": "flot",
|
||||
+ "seriesOverrides": [
|
||||
+
|
||||
+ ],
|
||||
+ "spaceLength": 10,
|
||||
+ "span": 6,
|
||||
+ "stack": true,
|
||||
+ "steppedLine": false,
|
||||
+ "targets": [
|
||||
+ {
|
||||
+ "expr": "sum(irate(container_network_transmit_packets_dropped_total{cluster=\"$cluster\", namespace=~\"$namespace\"}[$__rate_interval])) by (pod)",
|
||||
+ "format": "time_series",
|
||||
+ "intervalFactor": 2,
|
||||
+ "legendFormat": "{{`{{`}}pod{{`}}`}}",
|
||||
+ "legendLink": null,
|
||||
+ "step": 10
|
||||
+ }
|
||||
+ ],
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "timeFrom": null,
|
||||
+ "timeShift": null,
|
||||
+ "title": "Rate of Transmitted Packets Dropped",
|
||||
+ "tooltip": {
|
||||
+ "shared": false,
|
||||
+ "sort": 0,
|
||||
+ "value_type": "individual"
|
||||
+ },
|
||||
+ "type": "graph",
|
||||
+ "xaxis": {
|
||||
+ "buckets": null,
|
||||
+ "mode": "time",
|
||||
+ "name": null,
|
||||
+ "show": true,
|
||||
+ "values": [
|
||||
+
|
||||
+ ]
|
||||
+ },
|
||||
+ "yaxes": [
|
||||
+ {
|
||||
+ "format": "Bps",
|
||||
+ "label": null,
|
||||
+ "logBase": 1,
|
||||
+ "max": null,
|
||||
+ "min": 0,
|
||||
+ "show": true
|
||||
+ },
|
||||
+ {
|
||||
+ "format": "short",
|
||||
+ "label": null,
|
||||
+ "logBase": 1,
|
||||
+ "max": null,
|
||||
+ "min": null,
|
||||
+ "show": false
|
||||
+ }
|
||||
+ ]
|
||||
}
|
||||
],
|
||||
"repeat": null,
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Rate of Packets Dropped",
|
||||
"titleSize": "h6"
|
||||
},
|
||||
{
|
||||
@@ -2083,8 +2149,9 @@
|
||||
"dashLength": 10,
|
||||
"dashes": false,
|
||||
"datasource": "$datasource",
|
||||
+ "decimals": -1,
|
||||
"fill": 10,
|
||||
- "id": 15,
|
||||
+ "id": 16,
|
||||
"legend": {
|
||||
"avg": false,
|
||||
"current": false,
|
||||
@@ -2108,12 +2175,12 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "sum(irate(container_network_transmit_packets_dropped_total{cluster=\"$cluster\", namespace=~\"$namespace\"}[$__rate_interval])) by (pod)",
|
||||
+ "expr": "ceil(sum by(pod) (rate(container_fs_reads_total{container!=\"\", cluster=\"$cluster\",namespace=~\"$namespace\"}[5m]) + rate(container_fs_writes_total{container!=\"\", cluster=\"$cluster\",namespace=~\"$namespace\"}[5m])))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}pod{{`}}`}}",
|
||||
@@ -2126,7 +2193,93 @@
|
||||
],
|
||||
"timeFrom": null,
|
||||
"timeShift": null,
|
||||
- "title": "Rate of Transmitted Packets Dropped",
|
||||
+ "title": "IOPS(Reads+Writes)",
|
||||
+ "tooltip": {
|
||||
+ "shared": false,
|
||||
+ "sort": 0,
|
||||
+ "value_type": "individual"
|
||||
+ },
|
||||
+ "type": "graph",
|
||||
+ "xaxis": {
|
||||
+ "buckets": null,
|
||||
+ "mode": "time",
|
||||
+ "name": null,
|
||||
+ "show": true,
|
||||
+ "values": [
|
||||
+
|
||||
+ ]
|
||||
+ },
|
||||
+ "yaxes": [
|
||||
+ {
|
||||
+ "format": "short",
|
||||
+ "label": null,
|
||||
+ "logBase": 1,
|
||||
+ "max": null,
|
||||
+ "min": 0,
|
||||
+ "show": true
|
||||
+ },
|
||||
+ {
|
||||
+ "format": "short",
|
||||
+ "label": null,
|
||||
+ "logBase": 1,
|
||||
+ "max": null,
|
||||
+ "min": null,
|
||||
+ "show": false
|
||||
+ }
|
||||
+ ]
|
||||
+ },
|
||||
+ {
|
||||
+ "aliasColors": {
|
||||
+
|
||||
+ },
|
||||
+ "bars": false,
|
||||
+ "dashLength": 10,
|
||||
+ "dashes": false,
|
||||
+ "datasource": "$datasource",
|
||||
+ "fill": 10,
|
||||
+ "id": 17,
|
||||
+ "legend": {
|
||||
+ "avg": false,
|
||||
+ "current": false,
|
||||
+ "max": false,
|
||||
+ "min": false,
|
||||
+ "show": true,
|
||||
+ "total": false,
|
||||
+ "values": false
|
||||
+ },
|
||||
+ "lines": true,
|
||||
+ "linewidth": 0,
|
||||
+ "links": [
|
||||
+
|
||||
+ ],
|
||||
+ "nullPointMode": "null as zero",
|
||||
+ "percentage": false,
|
||||
+ "pointradius": 5,
|
||||
+ "points": false,
|
||||
+ "renderer": "flot",
|
||||
+ "seriesOverrides": [
|
||||
+
|
||||
+ ],
|
||||
+ "spaceLength": 10,
|
||||
+ "span": 6,
|
||||
+ "stack": true,
|
||||
+ "steppedLine": false,
|
||||
+ "targets": [
|
||||
+ {
|
||||
+ "expr": "sum by(pod) (rate(container_fs_reads_bytes_total{container!=\"\", cluster=\"$cluster\",namespace=~\"$namespace\"}[5m]) + rate(container_fs_writes_bytes_total{container!=\"\", cluster=\"$cluster\",namespace=~\"$namespace\"}[5m]))",
|
||||
+ "format": "time_series",
|
||||
+ "intervalFactor": 2,
|
||||
+ "legendFormat": "{{`{{`}}pod{{`}}`}}",
|
||||
+ "legendLink": null,
|
||||
+ "step": 10
|
||||
+ }
|
||||
+ ],
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "timeFrom": null,
|
||||
+ "timeShift": null,
|
||||
+ "title": "ThroughPut(Read+Write)",
|
||||
"tooltip": {
|
||||
"shared": false,
|
||||
"sort": 0,
|
||||
@@ -2166,7 +2319,312 @@
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Storage IO",
|
||||
+ "titleSize": "h6"
|
||||
+ },
|
||||
+ {
|
||||
+ "collapse": false,
|
||||
+ "height": "250px",
|
||||
+ "panels": [
|
||||
+ {
|
||||
+ "aliasColors": {
|
||||
+
|
||||
+ },
|
||||
+ "bars": false,
|
||||
+ "dashLength": 10,
|
||||
+ "dashes": false,
|
||||
+ "datasource": "$datasource",
|
||||
+ "fill": 1,
|
||||
+ "id": 18,
|
||||
+ "legend": {
|
||||
+ "avg": false,
|
||||
+ "current": false,
|
||||
+ "max": false,
|
||||
+ "min": false,
|
||||
+ "show": true,
|
||||
+ "total": false,
|
||||
+ "values": false
|
||||
+ },
|
||||
+ "lines": true,
|
||||
+ "linewidth": 1,
|
||||
+ "links": [
|
||||
+
|
||||
+ ],
|
||||
+ "nullPointMode": "null as zero",
|
||||
+ "percentage": false,
|
||||
+ "pointradius": 5,
|
||||
+ "points": false,
|
||||
+ "renderer": "flot",
|
||||
+ "seriesOverrides": [
|
||||
+
|
||||
+ ],
|
||||
+ "sort": {
|
||||
+ "col": 4,
|
||||
+ "desc": true
|
||||
+ },
|
||||
+ "spaceLength": 10,
|
||||
+ "span": 12,
|
||||
+ "stack": false,
|
||||
+ "steppedLine": false,
|
||||
+ "styles": [
|
||||
+ {
|
||||
+ "alias": "Time",
|
||||
+ "dateFormat": "YYYY-MM-DD HH:mm:ss",
|
||||
+ "pattern": "Time",
|
||||
+ "type": "hidden"
|
||||
+ },
|
||||
+ {
|
||||
+ "alias": "IOPS(Reads)",
|
||||
+ "colorMode": null,
|
||||
+ "colors": [
|
||||
+
|
||||
+ ],
|
||||
+ "dateFormat": "YYYY-MM-DD HH:mm:ss",
|
||||
+ "decimals": -1,
|
||||
+ "link": false,
|
||||
+ "linkTargetBlank": false,
|
||||
+ "linkTooltip": "Drill down",
|
||||
+ "linkUrl": "",
|
||||
+ "pattern": "Value #A",
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "type": "number",
|
||||
+ "unit": "short"
|
||||
+ },
|
||||
+ {
|
||||
+ "alias": "IOPS(Writes)",
|
||||
+ "colorMode": null,
|
||||
+ "colors": [
|
||||
+
|
||||
+ ],
|
||||
+ "dateFormat": "YYYY-MM-DD HH:mm:ss",
|
||||
+ "decimals": -1,
|
||||
+ "link": false,
|
||||
+ "linkTargetBlank": false,
|
||||
+ "linkTooltip": "Drill down",
|
||||
+ "linkUrl": "",
|
||||
+ "pattern": "Value #B",
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "type": "number",
|
||||
+ "unit": "short"
|
||||
+ },
|
||||
+ {
|
||||
+ "alias": "IOPS(Reads + Writes)",
|
||||
+ "colorMode": null,
|
||||
+ "colors": [
|
||||
+
|
||||
+ ],
|
||||
+ "dateFormat": "YYYY-MM-DD HH:mm:ss",
|
||||
+ "decimals": -1,
|
||||
+ "link": false,
|
||||
+ "linkTargetBlank": false,
|
||||
+ "linkTooltip": "Drill down",
|
||||
+ "linkUrl": "",
|
||||
+ "pattern": "Value #C",
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "type": "number",
|
||||
+ "unit": "short"
|
||||
+ },
|
||||
+ {
|
||||
+ "alias": "Throughput(Read)",
|
||||
+ "colorMode": null,
|
||||
+ "colors": [
|
||||
+
|
||||
+ ],
|
||||
+ "dateFormat": "YYYY-MM-DD HH:mm:ss",
|
||||
+ "decimals": 2,
|
||||
+ "link": false,
|
||||
+ "linkTargetBlank": false,
|
||||
+ "linkTooltip": "Drill down",
|
||||
+ "linkUrl": "",
|
||||
+ "pattern": "Value #D",
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "type": "number",
|
||||
+ "unit": "Bps"
|
||||
+ },
|
||||
+ {
|
||||
+ "alias": "Throughput(Write)",
|
||||
+ "colorMode": null,
|
||||
+ "colors": [
|
||||
+
|
||||
+ ],
|
||||
+ "dateFormat": "YYYY-MM-DD HH:mm:ss",
|
||||
+ "decimals": 2,
|
||||
+ "link": false,
|
||||
+ "linkTargetBlank": false,
|
||||
+ "linkTooltip": "Drill down",
|
||||
+ "linkUrl": "",
|
||||
+ "pattern": "Value #E",
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "type": "number",
|
||||
+ "unit": "Bps"
|
||||
+ },
|
||||
+ {
|
||||
+ "alias": "Throughput(Read + Write)",
|
||||
+ "colorMode": null,
|
||||
+ "colors": [
|
||||
+
|
||||
+ ],
|
||||
+ "dateFormat": "YYYY-MM-DD HH:mm:ss",
|
||||
+ "decimals": 2,
|
||||
+ "link": false,
|
||||
+ "linkTargetBlank": false,
|
||||
+ "linkTooltip": "Drill down",
|
||||
+ "linkUrl": "",
|
||||
+ "pattern": "Value #F",
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "type": "number",
|
||||
+ "unit": "Bps"
|
||||
+ },
|
||||
+ {
|
||||
+ "alias": "Pod",
|
||||
+ "colorMode": null,
|
||||
+ "colors": [
|
||||
+
|
||||
+ ],
|
||||
+ "dateFormat": "YYYY-MM-DD HH:mm:ss",
|
||||
+ "decimals": 2,
|
||||
+ "link": true,
|
||||
+ "linkTargetBlank": false,
|
||||
+ "linkTooltip": "Drill down to pods",
|
||||
+ "linkUrl": "./d/6581e46e4e5c7ba40a07646395ef7b23/k8s-resources-pod?var-datasource=$datasource&var-cluster=$cluster&var-namespace=$namespace&var-pod=$__cell",
|
||||
+ "pattern": "pod",
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "type": "number",
|
||||
+ "unit": "short"
|
||||
+ },
|
||||
+ {
|
||||
+ "alias": "",
|
||||
+ "colorMode": null,
|
||||
+ "colors": [
|
||||
+
|
||||
+ ],
|
||||
+ "dateFormat": "YYYY-MM-DD HH:mm:ss",
|
||||
+ "decimals": 2,
|
||||
+ "pattern": "/.*/",
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "type": "string",
|
||||
+ "unit": "short"
|
||||
+ }
|
||||
+ ],
|
||||
+ "targets": [
|
||||
+ {
|
||||
+ "expr": "sum by(pod) (rate(container_fs_reads_total{container!=\"\", cluster=\"$cluster\",namespace=~\"$namespace\"}[5m]))",
|
||||
+ "format": "table",
|
||||
+ "instant": true,
|
||||
+ "intervalFactor": 2,
|
||||
+ "legendFormat": "",
|
||||
+ "refId": "A",
|
||||
+ "step": 10
|
||||
+ },
|
||||
+ {
|
||||
+ "expr": "sum by(pod) (rate(container_fs_writes_total{container!=\"\", cluster=\"$cluster\",namespace=~\"$namespace\"}[5m]))",
|
||||
+ "format": "table",
|
||||
+ "instant": true,
|
||||
+ "intervalFactor": 2,
|
||||
+ "legendFormat": "",
|
||||
+ "refId": "B",
|
||||
+ "step": 10
|
||||
+ },
|
||||
+ {
|
||||
+ "expr": "sum by(pod) (rate(container_fs_reads_total{container!=\"\", cluster=\"$cluster\",namespace=~\"$namespace\"}[5m]) + rate(container_fs_writes_total{container!=\"\", cluster=\"$cluster\",namespace=~\"$namespace\"}[5m]))",
|
||||
+ "format": "table",
|
||||
+ "instant": true,
|
||||
+ "intervalFactor": 2,
|
||||
+ "legendFormat": "",
|
||||
+ "refId": "C",
|
||||
+ "step": 10
|
||||
+ },
|
||||
+ {
|
||||
+ "expr": "sum by(pod) (rate(container_fs_reads_bytes_total{container!=\"\", cluster=\"$cluster\",namespace=~\"$namespace\"}[5m]))",
|
||||
+ "format": "table",
|
||||
+ "instant": true,
|
||||
+ "intervalFactor": 2,
|
||||
+ "legendFormat": "",
|
||||
+ "refId": "D",
|
||||
+ "step": 10
|
||||
+ },
|
||||
+ {
|
||||
+ "expr": "sum by(pod) (rate(container_fs_writes_bytes_total{container!=\"\", cluster=\"$cluster\",namespace=~\"$namespace\"}[5m]))",
|
||||
+ "format": "table",
|
||||
+ "instant": true,
|
||||
+ "intervalFactor": 2,
|
||||
+ "legendFormat": "",
|
||||
+ "refId": "E",
|
||||
+ "step": 10
|
||||
+ },
|
||||
+ {
|
||||
+ "expr": "sum by(pod) (rate(container_fs_reads_bytes_total{container!=\"\", cluster=\"$cluster\",namespace=~\"$namespace\"}[5m]) + rate(container_fs_writes_bytes_total{container!=\"\", cluster=\"$cluster\",namespace=~\"$namespace\"}[5m]))",
|
||||
+ "format": "table",
|
||||
+ "instant": true,
|
||||
+ "intervalFactor": 2,
|
||||
+ "legendFormat": "",
|
||||
+ "refId": "F",
|
||||
+ "step": 10
|
||||
+ }
|
||||
+ ],
|
||||
+ "thresholds": [
|
||||
+
|
||||
+ ],
|
||||
+ "timeFrom": null,
|
||||
+ "timeShift": null,
|
||||
+ "title": "Current Storage IO",
|
||||
+ "tooltip": {
|
||||
+ "shared": false,
|
||||
+ "sort": 0,
|
||||
+ "value_type": "individual"
|
||||
+ },
|
||||
+ "transform": "table",
|
||||
+ "type": "table",
|
||||
+ "xaxis": {
|
||||
+ "buckets": null,
|
||||
+ "mode": "time",
|
||||
+ "name": null,
|
||||
+ "show": true,
|
||||
+ "values": [
|
||||
+
|
||||
+ ]
|
||||
+ },
|
||||
+ "yaxes": [
|
||||
+ {
|
||||
+ "format": "short",
|
||||
+ "label": null,
|
||||
+ "logBase": 1,
|
||||
+ "max": null,
|
||||
+ "min": 0,
|
||||
+ "show": true
|
||||
+ },
|
||||
+ {
|
||||
+ "format": "short",
|
||||
+ "label": null,
|
||||
+ "logBase": 1,
|
||||
+ "max": null,
|
||||
+ "min": null,
|
||||
+ "show": false
|
||||
+ }
|
||||
+ ]
|
||||
+ }
|
||||
+ ],
|
||||
+ "repeat": null,
|
||||
+ "repeatIteration": null,
|
||||
+ "repeatRowId": null,
|
||||
+ "showTitle": true,
|
||||
+ "title": "Storage IO - Distribution",
|
||||
"titleSize": "h6"
|
||||
}
|
||||
],
|
||||
@@ -2209,7 +2667,7 @@
|
||||
|
||||
],
|
||||
"query": "label_values(kube_pod_info, cluster)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"sort": 1,
|
||||
"tagValuesQuery": "",
|
||||
@@ -2236,7 +2694,7 @@
|
||||
|
||||
],
|
||||
"query": "label_values(kube_pod_info{cluster=\"$cluster\"}, namespace)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"sort": 1,
|
||||
"tagValuesQuery": "",
|
||||
@@ -2283,4 +2741,4 @@
|
||||
"uid": "85a562078cdf77779eaa1add43ccec1e",
|
||||
"version": 0
|
||||
}
|
||||
-{{- end }}
|
||||
\ No newline at end of file
|
||||
+{{- end }}
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/k8s-resources-node.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/k8s-resources-node.yaml
|
||||
@@ -8,7 +8,7 @@
|
||||
@@ -4,11 +4,11 @@
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
@ -9,3 +14,100 @@
|
|||
name: {{ printf "%s-%s" (include "kube-prometheus-stack.fullname" $) "k8s-resources-node" | trunc 63 | trimSuffix "-" }}
|
||||
annotations:
|
||||
{{ toYaml .Values.grafana.sidecar.dashboards.annotations | indent 4 }}
|
||||
@@ -321,7 +321,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(kube_pod_container_resource_requests_cpu_cores{cluster=\"$cluster\", node=~\"$node\"}) by (pod)",
|
||||
+ "expr": "sum(kube_pod_container_resource_requests{cluster=\"$cluster\", node=~\"$node\", resource=\"cpu\"}) by (pod)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -330,7 +330,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", node=~\"$node\"}) by (pod) / sum(kube_pod_container_resource_requests_cpu_cores{cluster=\"$cluster\", node=~\"$node\"}) by (pod)",
|
||||
+ "expr": "sum(node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", node=~\"$node\"}) by (pod) / sum(kube_pod_container_resource_requests{cluster=\"$cluster\", node=~\"$node\", resource=\"cpu\"}) by (pod)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -339,7 +339,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(kube_pod_container_resource_limits_cpu_cores{cluster=\"$cluster\", node=~\"$node\"}) by (pod)",
|
||||
+ "expr": "sum(kube_pod_container_resource_limits{cluster=\"$cluster\", node=~\"$node\", resource=\"cpu\"}) by (pod)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -348,7 +348,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", node=~\"$node\"}) by (pod) / sum(kube_pod_container_resource_limits_cpu_cores{cluster=\"$cluster\", node=~\"$node\"}) by (pod)",
|
||||
+ "expr": "sum(node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", node=~\"$node\"}) by (pod) / sum(kube_pod_container_resource_limits{cluster=\"$cluster\", node=~\"$node\", resource=\"cpu\"}) by (pod)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -749,7 +749,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(kube_pod_container_resource_requests_memory_bytes{cluster=\"$cluster\", node=~\"$node\"}) by (pod)",
|
||||
+ "expr": "sum(kube_pod_container_resource_requests{cluster=\"$cluster\", node=~\"$node\", resource=\"memory\"}) by (pod)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -758,7 +758,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(node_namespace_pod_container:container_memory_working_set_bytes{cluster=\"$cluster\", node=~\"$node\",container!=\"\"}) by (pod) / sum(kube_pod_container_resource_requests_memory_bytes{node=~\"$node\"}) by (pod)",
|
||||
+ "expr": "sum(node_namespace_pod_container:container_memory_working_set_bytes{cluster=\"$cluster\", node=~\"$node\",container!=\"\"}) by (pod) / sum(kube_pod_container_resource_requests{cluster=\"$cluster\", node=~\"$node\", resource=\"memory\"}) by (pod)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -767,7 +767,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(kube_pod_container_resource_limits_memory_bytes{cluster=\"$cluster\", node=~\"$node\"}) by (pod)",
|
||||
+ "expr": "sum(kube_pod_container_resource_limits{cluster=\"$cluster\", node=~\"$node\", resource=\"memory\"}) by (pod)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -776,7 +776,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(node_namespace_pod_container:container_memory_working_set_bytes{cluster=\"$cluster\", node=~\"$node\",container!=\"\"}) by (pod) / sum(kube_pod_container_resource_limits_memory_bytes{node=~\"$node\"}) by (pod)",
|
||||
+ "expr": "sum(node_namespace_pod_container:container_memory_working_set_bytes{cluster=\"$cluster\", node=~\"$node\",container!=\"\"}) by (pod) / sum(kube_pod_container_resource_limits{cluster=\"$cluster\", node=~\"$node\", resource=\"memory\"}) by (pod)",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -901,7 +901,7 @@
|
||||
|
||||
],
|
||||
"query": "label_values(kube_pod_info, cluster)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"sort": 1,
|
||||
"tagValuesQuery": "",
|
||||
@@ -928,7 +928,7 @@
|
||||
|
||||
],
|
||||
"query": "label_values(kube_pod_info{cluster=\"$cluster\"}, node)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"sort": 1,
|
||||
"tagValuesQuery": "",
|
||||
@@ -975,4 +975,4 @@
|
||||
"uid": "200ac8fdbfbb74b39aff88118e4d1c2c",
|
||||
"version": 0
|
||||
}
|
||||
-{{- end }}
|
||||
\ No newline at end of file
|
||||
+{{- end }}
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -1,6 +1,11 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/k8s-resources-workload.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/k8s-resources-workload.yaml
|
||||
@@ -8,7 +8,7 @@
|
||||
@@ -4,11 +4,11 @@
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
@ -9,3 +14,319 @@
|
|||
name: {{ printf "%s-%s" (include "kube-prometheus-stack.fullname" $) "k8s-resources-workload" | trunc 63 | trimSuffix "-" }}
|
||||
annotations:
|
||||
{{ toYaml .Values.grafana.sidecar.dashboards.annotations | indent 4 }}
|
||||
@@ -321,7 +321,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(\n kube_pod_container_resource_requests_cpu_cores{cluster=\"$cluster\", namespace=\"$namespace\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n",
|
||||
+ "expr": "sum(\n kube_pod_container_resource_requests{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"cpu\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -330,7 +330,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(\n node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", namespace=\"$namespace\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n/sum(\n kube_pod_container_resource_requests_cpu_cores{cluster=\"$cluster\", namespace=\"$namespace\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n",
|
||||
+ "expr": "sum(\n node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", namespace=\"$namespace\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n/sum(\n kube_pod_container_resource_requests{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"cpu\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -339,7 +339,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(\n kube_pod_container_resource_limits_cpu_cores{cluster=\"$cluster\", namespace=\"$namespace\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n",
|
||||
+ "expr": "sum(\n kube_pod_container_resource_limits{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"cpu\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -348,7 +348,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(\n node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", namespace=\"$namespace\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n/sum(\n kube_pod_container_resource_limits_cpu_cores{cluster=\"$cluster\", namespace=\"$namespace\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n",
|
||||
+ "expr": "sum(\n node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", namespace=\"$namespace\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n/sum(\n kube_pod_container_resource_limits{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"cpu\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -692,7 +692,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(\n kube_pod_container_resource_requests_memory_bytes{cluster=\"$cluster\", namespace=\"$namespace\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n",
|
||||
+ "expr": "sum(\n kube_pod_container_resource_requests{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"memory\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -701,7 +701,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(\n container_memory_working_set_bytes{cluster=\"$cluster\", namespace=\"$namespace\", container!=\"\", image!=\"\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n/sum(\n kube_pod_container_resource_requests_memory_bytes{cluster=\"$cluster\", namespace=\"$namespace\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n",
|
||||
+ "expr": "sum(\n container_memory_working_set_bytes{cluster=\"$cluster\", namespace=\"$namespace\", container!=\"\", image!=\"\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n/sum(\n kube_pod_container_resource_requests{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"memory\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -710,7 +710,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(\n kube_pod_container_resource_limits_memory_bytes{cluster=\"$cluster\", namespace=\"$namespace\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n",
|
||||
+ "expr": "sum(\n kube_pod_container_resource_limits{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"memory\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -719,7 +719,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(\n container_memory_working_set_bytes{cluster=\"$cluster\", namespace=\"$namespace\", container!=\"\", image!=\"\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n/sum(\n kube_pod_container_resource_limits_memory_bytes{cluster=\"$cluster\", namespace=\"$namespace\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n",
|
||||
+ "expr": "sum(\n container_memory_working_set_bytes{cluster=\"$cluster\", namespace=\"$namespace\", container!=\"\", image!=\"\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n/sum(\n kube_pod_container_resource_limits{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"memory\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\", workload_type=\"$type\"}\n) by (pod)\n",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -1076,7 +1076,7 @@
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Current Network Usage",
|
||||
"titleSize": "h6"
|
||||
},
|
||||
{
|
||||
@@ -1116,7 +1116,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1168,19 +1168,7 @@
|
||||
"show": false
|
||||
}
|
||||
]
|
||||
- }
|
||||
- ],
|
||||
- "repeat": null,
|
||||
- "repeatIteration": null,
|
||||
- "repeatRowId": null,
|
||||
- "showTitle": true,
|
||||
- "title": "Network",
|
||||
- "titleSize": "h6"
|
||||
- },
|
||||
- {
|
||||
- "collapse": false,
|
||||
- "height": "250px",
|
||||
- "panels": [
|
||||
+ },
|
||||
{
|
||||
"aliasColors": {
|
||||
|
||||
@@ -1214,7 +1202,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1272,7 +1260,7 @@
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Bandwidth",
|
||||
"titleSize": "h6"
|
||||
},
|
||||
{
|
||||
@@ -1312,7 +1300,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1364,19 +1352,7 @@
|
||||
"show": false
|
||||
}
|
||||
]
|
||||
- }
|
||||
- ],
|
||||
- "repeat": null,
|
||||
- "repeatIteration": null,
|
||||
- "repeatRowId": null,
|
||||
- "showTitle": true,
|
||||
- "title": "Network",
|
||||
- "titleSize": "h6"
|
||||
- },
|
||||
- {
|
||||
- "collapse": false,
|
||||
- "height": "250px",
|
||||
- "panels": [
|
||||
+ },
|
||||
{
|
||||
"aliasColors": {
|
||||
|
||||
@@ -1410,7 +1386,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1468,7 +1444,7 @@
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Average Container Bandwidth by Pod",
|
||||
"titleSize": "h6"
|
||||
},
|
||||
{
|
||||
@@ -1508,7 +1484,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1560,19 +1536,7 @@
|
||||
"show": false
|
||||
}
|
||||
]
|
||||
- }
|
||||
- ],
|
||||
- "repeat": null,
|
||||
- "repeatIteration": null,
|
||||
- "repeatRowId": null,
|
||||
- "showTitle": true,
|
||||
- "title": "Network",
|
||||
- "titleSize": "h6"
|
||||
- },
|
||||
- {
|
||||
- "collapse": false,
|
||||
- "height": "250px",
|
||||
- "panels": [
|
||||
+ },
|
||||
{
|
||||
"aliasColors": {
|
||||
|
||||
@@ -1606,7 +1570,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1664,7 +1628,7 @@
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Rate of Packets",
|
||||
"titleSize": "h6"
|
||||
},
|
||||
{
|
||||
@@ -1704,7 +1668,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1756,19 +1720,7 @@
|
||||
"show": false
|
||||
}
|
||||
]
|
||||
- }
|
||||
- ],
|
||||
- "repeat": null,
|
||||
- "repeatIteration": null,
|
||||
- "repeatRowId": null,
|
||||
- "showTitle": true,
|
||||
- "title": "Network",
|
||||
- "titleSize": "h6"
|
||||
- },
|
||||
- {
|
||||
- "collapse": false,
|
||||
- "height": "250px",
|
||||
- "panels": [
|
||||
+ },
|
||||
{
|
||||
"aliasColors": {
|
||||
|
||||
@@ -1802,7 +1754,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1860,7 +1812,7 @@
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Rate of Packets Dropped",
|
||||
"titleSize": "h6"
|
||||
}
|
||||
],
|
||||
@@ -1903,7 +1855,7 @@
|
||||
|
||||
],
|
||||
"query": "label_values(kube_pod_info, cluster)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"sort": 1,
|
||||
"tagValuesQuery": "",
|
||||
@@ -1930,7 +1882,7 @@
|
||||
|
||||
],
|
||||
"query": "label_values(kube_pod_info{cluster=\"$cluster\"}, namespace)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"sort": 1,
|
||||
"tagValuesQuery": "",
|
||||
@@ -1957,7 +1909,7 @@
|
||||
|
||||
],
|
||||
"query": "label_values(namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\"}, workload)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"sort": 1,
|
||||
"tagValuesQuery": "",
|
||||
@@ -1984,7 +1936,7 @@
|
||||
|
||||
],
|
||||
"query": "label_values(namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload=\"$workload\"}, workload_type)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"sort": 1,
|
||||
"tagValuesQuery": "",
|
||||
@@ -2031,4 +1983,4 @@
|
||||
"uid": "a164a7f0339f99e89cea5cb47e9be617",
|
||||
"version": 0
|
||||
}
|
||||
-{{- end }}
|
||||
\ No newline at end of file
|
||||
+{{- end }}
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/k8s-resources-workloads-namespace.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/k8s-resources-workloads-namespace.yaml
|
||||
@@ -8,7 +8,7 @@
|
||||
@@ -4,11 +4,11 @@
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
@ -9,3 +14,408 @@
|
|||
name: {{ printf "%s-%s" (include "kube-prometheus-stack.fullname" $) "k8s-resources-workloads-namespace" | trunc 63 | trimSuffix "-" }}
|
||||
annotations:
|
||||
{{ toYaml .Values.grafana.sidecar.dashboards.annotations | indent 4 }}
|
||||
@@ -74,8 +74,9 @@
|
||||
"color": "#F2495C",
|
||||
"dashes": true,
|
||||
"fill": 0,
|
||||
+ "hiddenSeries": true,
|
||||
"hideTooltip": true,
|
||||
- "legend": false,
|
||||
+ "legend": true,
|
||||
"linewidth": 2,
|
||||
"stack": false
|
||||
},
|
||||
@@ -84,8 +85,9 @@
|
||||
"color": "#FF9830",
|
||||
"dashes": true,
|
||||
"fill": 0,
|
||||
+ "hiddenSeries": true,
|
||||
"hideTooltip": true,
|
||||
- "legend": false,
|
||||
+ "legend": true,
|
||||
"linewidth": 2,
|
||||
"stack": false
|
||||
}
|
||||
@@ -403,7 +405,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(\n kube_pod_container_resource_requests_cpu_cores{cluster=\"$cluster\", namespace=\"$namespace\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n",
|
||||
+ "expr": "sum(\n kube_pod_container_resource_requests{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"cpu\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -412,7 +414,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(\n node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", namespace=\"$namespace\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n/sum(\n kube_pod_container_resource_requests_cpu_cores{cluster=\"$cluster\", namespace=\"$namespace\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n",
|
||||
+ "expr": "sum(\n node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", namespace=\"$namespace\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n/sum(\n kube_pod_container_resource_requests{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"cpu\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -421,7 +423,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(\n kube_pod_container_resource_limits_cpu_cores{cluster=\"$cluster\", namespace=\"$namespace\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n",
|
||||
+ "expr": "sum(\n kube_pod_container_resource_limits{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"cpu\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -430,7 +432,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(\n node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", namespace=\"$namespace\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n/sum(\n kube_pod_container_resource_limits_cpu_cores{cluster=\"$cluster\", namespace=\"$namespace\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n",
|
||||
+ "expr": "sum(\n node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{cluster=\"$cluster\", namespace=\"$namespace\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n/sum(\n kube_pod_container_resource_limits{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"cpu\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -527,8 +529,9 @@
|
||||
"color": "#F2495C",
|
||||
"dashes": true,
|
||||
"fill": 0,
|
||||
+ "hiddenSeries": true,
|
||||
"hideTooltip": true,
|
||||
- "legend": false,
|
||||
+ "legend": true,
|
||||
"linewidth": 2,
|
||||
"stack": false
|
||||
},
|
||||
@@ -537,8 +540,9 @@
|
||||
"color": "#FF9830",
|
||||
"dashes": true,
|
||||
"fill": 0,
|
||||
+ "hiddenSeries": true,
|
||||
"hideTooltip": true,
|
||||
- "legend": false,
|
||||
+ "legend": true,
|
||||
"linewidth": 2,
|
||||
"stack": false
|
||||
}
|
||||
@@ -856,7 +860,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(\n kube_pod_container_resource_requests_memory_bytes{cluster=\"$cluster\", namespace=\"$namespace\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n",
|
||||
+ "expr": "sum(\n kube_pod_container_resource_requests{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"memory\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -865,7 +869,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(\n container_memory_working_set_bytes{cluster=\"$cluster\", namespace=\"$namespace\", container!=\"\", image!=\"\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n/sum(\n kube_pod_container_resource_requests_memory_bytes{cluster=\"$cluster\", namespace=\"$namespace\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n",
|
||||
+ "expr": "sum(\n container_memory_working_set_bytes{cluster=\"$cluster\", namespace=\"$namespace\", container!=\"\", image!=\"\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n/sum(\n kube_pod_container_resource_requests{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"memory\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -874,7 +878,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(\n kube_pod_container_resource_limits_memory_bytes{cluster=\"$cluster\", namespace=\"$namespace\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n",
|
||||
+ "expr": "sum(\n kube_pod_container_resource_limits{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"memory\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -883,7 +887,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "sum(\n container_memory_working_set_bytes{cluster=\"$cluster\", namespace=\"$namespace\", container!=\"\", image!=\"\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n/sum(\n kube_pod_container_resource_limits_memory_bytes{cluster=\"$cluster\", namespace=\"$namespace\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n",
|
||||
+ "expr": "sum(\n container_memory_working_set_bytes{cluster=\"$cluster\", namespace=\"$namespace\", container!=\"\", image!=\"\"}\n * on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n/sum(\n kube_pod_container_resource_limits{cluster=\"$cluster\", namespace=\"$namespace\", resource=\"memory\"}\n* on(namespace,pod)\n group_left(workload, workload_type) namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=\"$namespace\", workload_type=\"$type\"}\n) by (workload, workload_type)\n",
|
||||
"format": "table",
|
||||
"instant": true,
|
||||
"intervalFactor": 2,
|
||||
@@ -1259,7 +1263,7 @@
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Current Network Usage",
|
||||
"titleSize": "h6"
|
||||
},
|
||||
{
|
||||
@@ -1299,7 +1303,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1351,19 +1355,7 @@
|
||||
"show": false
|
||||
}
|
||||
]
|
||||
- }
|
||||
- ],
|
||||
- "repeat": null,
|
||||
- "repeatIteration": null,
|
||||
- "repeatRowId": null,
|
||||
- "showTitle": true,
|
||||
- "title": "Network",
|
||||
- "titleSize": "h6"
|
||||
- },
|
||||
- {
|
||||
- "collapse": false,
|
||||
- "height": "250px",
|
||||
- "panels": [
|
||||
+ },
|
||||
{
|
||||
"aliasColors": {
|
||||
|
||||
@@ -1397,7 +1389,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1455,7 +1447,7 @@
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Bandwidth",
|
||||
"titleSize": "h6"
|
||||
},
|
||||
{
|
||||
@@ -1495,7 +1487,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1547,19 +1539,7 @@
|
||||
"show": false
|
||||
}
|
||||
]
|
||||
- }
|
||||
- ],
|
||||
- "repeat": null,
|
||||
- "repeatIteration": null,
|
||||
- "repeatRowId": null,
|
||||
- "showTitle": true,
|
||||
- "title": "Network",
|
||||
- "titleSize": "h6"
|
||||
- },
|
||||
- {
|
||||
- "collapse": false,
|
||||
- "height": "250px",
|
||||
- "panels": [
|
||||
+ },
|
||||
{
|
||||
"aliasColors": {
|
||||
|
||||
@@ -1593,7 +1573,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1651,7 +1631,7 @@
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Average Container Bandwidth by Workload",
|
||||
"titleSize": "h6"
|
||||
},
|
||||
{
|
||||
@@ -1691,7 +1671,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1743,19 +1723,7 @@
|
||||
"show": false
|
||||
}
|
||||
]
|
||||
- }
|
||||
- ],
|
||||
- "repeat": null,
|
||||
- "repeatIteration": null,
|
||||
- "repeatRowId": null,
|
||||
- "showTitle": true,
|
||||
- "title": "Network",
|
||||
- "titleSize": "h6"
|
||||
- },
|
||||
- {
|
||||
- "collapse": false,
|
||||
- "height": "250px",
|
||||
- "panels": [
|
||||
+ },
|
||||
{
|
||||
"aliasColors": {
|
||||
|
||||
@@ -1789,7 +1757,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1847,7 +1815,7 @@
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Rate of Packets",
|
||||
"titleSize": "h6"
|
||||
},
|
||||
{
|
||||
@@ -1887,7 +1855,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -1939,19 +1907,7 @@
|
||||
"show": false
|
||||
}
|
||||
]
|
||||
- }
|
||||
- ],
|
||||
- "repeat": null,
|
||||
- "repeatIteration": null,
|
||||
- "repeatRowId": null,
|
||||
- "showTitle": true,
|
||||
- "title": "Network",
|
||||
- "titleSize": "h6"
|
||||
- },
|
||||
- {
|
||||
- "collapse": false,
|
||||
- "height": "250px",
|
||||
- "panels": [
|
||||
+ },
|
||||
{
|
||||
"aliasColors": {
|
||||
|
||||
@@ -1985,7 +1941,7 @@
|
||||
|
||||
],
|
||||
"spaceLength": 10,
|
||||
- "span": 12,
|
||||
+ "span": 6,
|
||||
"stack": true,
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
@@ -2043,7 +1999,7 @@
|
||||
"repeatIteration": null,
|
||||
"repeatRowId": null,
|
||||
"showTitle": true,
|
||||
- "title": "Network",
|
||||
+ "title": "Rate of Packets Dropped",
|
||||
"titleSize": "h6"
|
||||
}
|
||||
],
|
||||
@@ -2072,28 +2028,23 @@
|
||||
},
|
||||
{
|
||||
"allValue": null,
|
||||
- "auto": false,
|
||||
- "auto_count": 30,
|
||||
- "auto_min": "10s",
|
||||
"current": {
|
||||
- "text": "deployment",
|
||||
- "value": "deployment"
|
||||
+ "text": "",
|
||||
+ "value": ""
|
||||
},
|
||||
"datasource": "$datasource",
|
||||
- "definition": "label_values(namespace_workload_pod:kube_pod_owner:relabel{namespace=~\"$namespace\", workload=~\".+\"}, workload_type)",
|
||||
- "hide": 0,
|
||||
+ "hide": {{ if .Values.grafana.sidecar.dashboards.multicluster }}0{{ else }}2{{ end }},
|
||||
"includeAll": false,
|
||||
"label": null,
|
||||
"multi": false,
|
||||
- "name": "type",
|
||||
+ "name": "cluster",
|
||||
"options": [
|
||||
|
||||
],
|
||||
- "query": "label_values(namespace_workload_pod:kube_pod_owner:relabel{namespace=~\"$namespace\", workload=~\".+\"}, workload_type)",
|
||||
- "refresh": 1,
|
||||
+ "query": "label_values(kube_pod_info, cluster)",
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
- "skipUrlSync": false,
|
||||
- "sort": 0,
|
||||
+ "sort": 1,
|
||||
"tagValuesQuery": "",
|
||||
"tags": [
|
||||
|
||||
@@ -2104,23 +2055,28 @@
|
||||
},
|
||||
{
|
||||
"allValue": null,
|
||||
+ "auto": false,
|
||||
+ "auto_count": 30,
|
||||
+ "auto_min": "10s",
|
||||
"current": {
|
||||
- "text": "",
|
||||
- "value": ""
|
||||
+ "text": "deployment",
|
||||
+ "value": "deployment"
|
||||
},
|
||||
"datasource": "$datasource",
|
||||
- "hide": {{ if .Values.grafana.sidecar.dashboards.multicluster }}0{{ else }}2{{ end }},
|
||||
+ "definition": "label_values(namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=~\"$namespace\", workload=~\".+\"}, workload_type)",
|
||||
+ "hide": 0,
|
||||
"includeAll": false,
|
||||
"label": null,
|
||||
"multi": false,
|
||||
- "name": "cluster",
|
||||
+ "name": "type",
|
||||
"options": [
|
||||
|
||||
],
|
||||
- "query": "label_values(kube_pod_info, cluster)",
|
||||
- "refresh": 1,
|
||||
+ "query": "label_values(namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\", namespace=~\"$namespace\", workload=~\".+\"}, workload_type)",
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
- "sort": 1,
|
||||
+ "skipUrlSync": false,
|
||||
+ "sort": 0,
|
||||
"tagValuesQuery": "",
|
||||
"tags": [
|
||||
|
||||
@@ -2145,7 +2101,7 @@
|
||||
|
||||
],
|
||||
"query": "label_values(kube_pod_info{cluster=\"$cluster\"}, namespace)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"sort": 1,
|
||||
"tagValuesQuery": "",
|
||||
@@ -2192,4 +2148,4 @@
|
||||
"uid": "a87fb0d919ec0ea5f6543124e16c42a5",
|
||||
"version": 0
|
||||
}
|
||||
-{{- end }}
|
||||
\ No newline at end of file
|
||||
+{{- end }}
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled .Values.kubelet.enabled }}
|
||||
+{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if (include "exporter.kubelet.enabled" .) }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
|
@ -20,10 +20,19 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "sum(up{cluster=\"$cluster\", job=\"kubelet\", metrics_path=\"/metrics\"})",
|
||||
+ "expr": "sum(up{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\"})",
|
||||
+ "expr": "sum(kubelet_node_name{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\"})",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "",
|
||||
@@ -115,7 +116,7 @@
|
||||
}
|
||||
],
|
||||
"thresholds": "",
|
||||
- "title": "Up",
|
||||
+ "title": "Running Kubelets",
|
||||
"tooltip": {
|
||||
"shared": false
|
||||
},
|
||||
@@ -191,7 +192,7 @@
|
||||
"tableColumn": "",
|
||||
"targets": [
|
||||
|
@ -284,6 +293,7 @@
|
|||
"uid": "3138fa155d5915769fbded898ac09fd9",
|
||||
"version": 0
|
||||
}
|
||||
+{{- end }}
|
||||
{{- end }}
|
||||
-{{- end }}
|
||||
\ No newline at end of file
|
||||
+{{- end }}
|
||||
+{{- end }}
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/namespace-by-pod.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/namespace-by-pod.yaml
|
||||
@@ -8,7 +8,7 @@
|
||||
@@ -4,11 +4,11 @@
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
@ -9,7 +14,7 @@
|
|||
name: {{ printf "%s-%s" (include "kube-prometheus-stack.fullname" $) "namespace-by-pod" | trunc 63 | trimSuffix "-" }}
|
||||
annotations:
|
||||
{{ toYaml .Values.grafana.sidecar.dashboards.annotations | indent 4 }}
|
||||
@@ -1295,7 +1295,7 @@
|
||||
@@ -1295,14 +1295,14 @@
|
||||
"datasource": "$datasource",
|
||||
"hide": {{ if .Values.grafana.sidecar.dashboards.multicluster }}0{{ else }}2{{ end }},
|
||||
"includeAll": false,
|
||||
|
@ -18,6 +23,23 @@
|
|||
"multi": false,
|
||||
"name": "cluster",
|
||||
"options": [
|
||||
|
||||
],
|
||||
"query": "label_values(kube_pod_info, cluster)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"sort": 0,
|
||||
"tagValuesQuery": "",
|
||||
@@ -1333,7 +1333,7 @@
|
||||
|
||||
],
|
||||
"query": "label_values(container_network_receive_packets_total{cluster=\"$cluster\"}, namespace)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"skipUrlSync": false,
|
||||
"sort": 1,
|
||||
@@ -1461,4 +1461,4 @@
|
||||
"uid": "8b7a8b326d7a6f1f04244066368c67af",
|
||||
"version": 0
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/namespace-by-workload.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/namespace-by-workload.yaml
|
||||
@@ -8,7 +8,7 @@
|
||||
@@ -4,11 +4,11 @@
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
@ -9,7 +14,7 @@
|
|||
name: {{ printf "%s-%s" (include "kube-prometheus-stack.fullname" $) "namespace-by-workload" | trunc 63 | trimSuffix "-" }}
|
||||
annotations:
|
||||
{{ toYaml .Values.grafana.sidecar.dashboards.annotations | indent 4 }}
|
||||
@@ -1535,7 +1535,7 @@
|
||||
@@ -1535,14 +1535,14 @@
|
||||
"datasource": "$datasource",
|
||||
"hide": {{ if .Values.grafana.sidecar.dashboards.multicluster }}0{{ else }}2{{ end }},
|
||||
"includeAll": false,
|
||||
|
@ -18,6 +23,32 @@
|
|||
"multi": false,
|
||||
"name": "cluster",
|
||||
"options": [
|
||||
|
||||
],
|
||||
"query": "label_values(kube_pod_info, cluster)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"sort": 0,
|
||||
"tagValuesQuery": "",
|
||||
@@ -1573,7 +1573,7 @@
|
||||
|
||||
],
|
||||
"query": "label_values(container_network_receive_packets_total{cluster=\"$cluster\"}, namespace)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"skipUrlSync": false,
|
||||
"sort": 1,
|
||||
@@ -1605,7 +1605,7 @@
|
||||
|
||||
],
|
||||
"query": "label_values(namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\",namespace=~\"$namespace\", workload=~\".+\"}, workload_type)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"skipUrlSync": false,
|
||||
"sort": 0,
|
||||
@@ -1733,4 +1733,4 @@
|
||||
"uid": "bbb2a765a623ae38130206c7d94a160f",
|
||||
"version": 0
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/node-cluster-rsrc-use.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/node-cluster-rsrc-use.yaml
|
||||
@@ -8,7 +8,7 @@
|
||||
@@ -4,11 +4,11 @@
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled .Values.nodeExporter.enabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled .Values.nodeExporter.enabled }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
@ -9,3 +14,163 @@
|
|||
name: {{ printf "%s-%s" (include "kube-prometheus-stack.fullname" $) "node-cluster-rsrc-use" | trunc 63 | trimSuffix "-" }}
|
||||
annotations:
|
||||
{{ toYaml .Values.grafana.sidecar.dashboards.annotations | indent 4 }}
|
||||
@@ -77,7 +77,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "(\n instance:node_cpu_utilisation:rate1m{job=\"node-exporter\"}\n*\n instance:node_num_cpu:sum{job=\"node-exporter\"}\n)\n/ scalar(sum(instance:node_num_cpu:sum{job=\"node-exporter\"}))\n",
|
||||
+ "expr": "(\n instance:node_cpu_utilisation:rate5m{job=\"node-exporter\"}\n*\n instance:node_num_cpu:sum{job=\"node-exporter\"}\n)\n/ scalar(sum(instance:node_num_cpu:sum{job=\"node-exporter\"}))\n",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}}",
|
||||
@@ -92,7 +92,7 @@
|
||||
"timeShift": null,
|
||||
"title": "CPU Utilisation",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -178,7 +178,7 @@
|
||||
"timeShift": null,
|
||||
"title": "CPU Saturation (load1 per CPU)",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -276,7 +276,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Memory Utilisation",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -347,7 +347,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "instance:node_vmstat_pgmajfault:rate1m{job=\"node-exporter\"}",
|
||||
+ "expr": "instance:node_vmstat_pgmajfault:rate5m{job=\"node-exporter\"}",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}}",
|
||||
@@ -362,7 +362,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Memory Saturation (Major Page Faults)",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -453,7 +453,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "instance:node_network_receive_bytes_excluding_lo:rate1m{job=\"node-exporter\"}",
|
||||
+ "expr": "instance:node_network_receive_bytes_excluding_lo:rate5m{job=\"node-exporter\"}",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}} Receive",
|
||||
@@ -461,7 +461,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "instance:node_network_transmit_bytes_excluding_lo:rate1m{job=\"node-exporter\"}",
|
||||
+ "expr": "instance:node_network_transmit_bytes_excluding_lo:rate5m{job=\"node-exporter\"}",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}} Transmit",
|
||||
@@ -476,7 +476,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Net Utilisation (Bytes Receive/Transmit)",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -555,7 +555,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "instance:node_network_receive_drop_excluding_lo:rate1m{job=\"node-exporter\"}",
|
||||
+ "expr": "instance:node_network_receive_drop_excluding_lo:rate5m{job=\"node-exporter\"}",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}} Receive",
|
||||
@@ -563,7 +563,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "instance:node_network_transmit_drop_excluding_lo:rate1m{job=\"node-exporter\"}",
|
||||
+ "expr": "instance:node_network_transmit_drop_excluding_lo:rate5m{job=\"node-exporter\"}",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}} Transmit",
|
||||
@@ -578,7 +578,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Net Saturation (Drops Receive/Transmit)",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -661,7 +661,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "instance_device:node_disk_io_time_seconds:rate1m{job=\"node-exporter\"}\n/ scalar(count(instance_device:node_disk_io_time_seconds:rate1m{job=\"node-exporter\"}))\n",
|
||||
+ "expr": "instance_device:node_disk_io_time_seconds:rate5m{job=\"node-exporter\"}\n/ scalar(count(instance_device:node_disk_io_time_seconds:rate5m{job=\"node-exporter\"}))\n",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}} {{`{{`}}device{{`}}`}}",
|
||||
@@ -676,7 +676,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Disk IO Utilisation",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -747,7 +747,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "instance_device:node_disk_io_time_weighted_seconds:rate1m{job=\"node-exporter\"}\n/ scalar(count(instance_device:node_disk_io_time_weighted_seconds:rate1m{job=\"node-exporter\"}))\n",
|
||||
+ "expr": "instance_device:node_disk_io_time_weighted_seconds:rate5m{job=\"node-exporter\"}\n/ scalar(count(instance_device:node_disk_io_time_weighted_seconds:rate5m{job=\"node-exporter\"}))\n",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}} {{`{{`}}device{{`}}`}}",
|
||||
@@ -762,7 +762,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Disk IO Saturation",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -860,7 +860,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Disk Space Utilisation",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -961,4 +961,4 @@
|
||||
"uid": "",
|
||||
"version": 0
|
||||
}
|
||||
-{{- end }}
|
||||
\ No newline at end of file
|
||||
+{{- end }}
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/node-rsrc-use.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/node-rsrc-use.yaml
|
||||
@@ -8,7 +8,7 @@
|
||||
@@ -4,11 +4,11 @@
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled .Values.nodeExporter.enabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled .Values.nodeExporter.enabled }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
@ -9,3 +14,163 @@
|
|||
name: {{ printf "%s-%s" (include "kube-prometheus-stack.fullname" $) "node-rsrc-use" | trunc 63 | trimSuffix "-" }}
|
||||
annotations:
|
||||
{{ toYaml .Values.grafana.sidecar.dashboards.annotations | indent 4 }}
|
||||
@@ -77,7 +77,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "instance:node_cpu_utilisation:rate1m{job=\"node-exporter\", instance=\"$instance\"}",
|
||||
+ "expr": "instance:node_cpu_utilisation:rate5m{job=\"node-exporter\", instance=\"$instance\"}",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "Utilisation",
|
||||
@@ -92,7 +92,7 @@
|
||||
"timeShift": null,
|
||||
"title": "CPU Utilisation",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -178,7 +178,7 @@
|
||||
"timeShift": null,
|
||||
"title": "CPU Saturation (Load1 per CPU)",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -276,7 +276,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Memory Utilisation",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -347,7 +347,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "instance:node_vmstat_pgmajfault:rate1m{job=\"node-exporter\", instance=\"$instance\"}",
|
||||
+ "expr": "instance:node_vmstat_pgmajfault:rate5m{job=\"node-exporter\", instance=\"$instance\"}",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "Major page faults",
|
||||
@@ -362,7 +362,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Memory Saturation (Major Page Faults)",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -453,7 +453,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "instance:node_network_receive_bytes_excluding_lo:rate1m{job=\"node-exporter\", instance=\"$instance\"}",
|
||||
+ "expr": "instance:node_network_receive_bytes_excluding_lo:rate5m{job=\"node-exporter\", instance=\"$instance\"}",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "Receive",
|
||||
@@ -461,7 +461,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "instance:node_network_transmit_bytes_excluding_lo:rate1m{job=\"node-exporter\", instance=\"$instance\"}",
|
||||
+ "expr": "instance:node_network_transmit_bytes_excluding_lo:rate5m{job=\"node-exporter\", instance=\"$instance\"}",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "Transmit",
|
||||
@@ -476,7 +476,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Net Utilisation (Bytes Receive/Transmit)",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -555,7 +555,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "instance:node_network_receive_drop_excluding_lo:rate1m{job=\"node-exporter\", instance=\"$instance\"}",
|
||||
+ "expr": "instance:node_network_receive_drop_excluding_lo:rate5m{job=\"node-exporter\", instance=\"$instance\"}",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "Receive drops",
|
||||
@@ -563,7 +563,7 @@
|
||||
"step": 10
|
||||
},
|
||||
{
|
||||
- "expr": "instance:node_network_transmit_drop_excluding_lo:rate1m{job=\"node-exporter\", instance=\"$instance\"}",
|
||||
+ "expr": "instance:node_network_transmit_drop_excluding_lo:rate5m{job=\"node-exporter\", instance=\"$instance\"}",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "Transmit drops",
|
||||
@@ -578,7 +578,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Net Saturation (Drops Receive/Transmit)",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -661,7 +661,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "instance_device:node_disk_io_time_seconds:rate1m{job=\"node-exporter\", instance=\"$instance\"}",
|
||||
+ "expr": "instance_device:node_disk_io_time_seconds:rate5m{job=\"node-exporter\", instance=\"$instance\"}",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}device{{`}}`}}",
|
||||
@@ -676,7 +676,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Disk IO Utilisation",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -747,7 +747,7 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "instance_device:node_disk_io_time_weighted_seconds:rate1m{job=\"node-exporter\", instance=\"$instance\"}",
|
||||
+ "expr": "instance_device:node_disk_io_time_weighted_seconds:rate5m{job=\"node-exporter\", instance=\"$instance\"}",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}device{{`}}`}}",
|
||||
@@ -762,7 +762,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Disk IO Saturation",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -860,7 +860,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Disk Space Utilisation",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -988,4 +988,4 @@
|
||||
"uid": "",
|
||||
"version": 0
|
||||
}
|
||||
-{{- end }}
|
||||
\ No newline at end of file
|
||||
+{{- end }}
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/nodes.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/nodes.yaml
|
||||
@@ -8,7 +8,7 @@
|
||||
@@ -4,11 +4,11 @@
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
@ -9,3 +14,72 @@
|
|||
name: {{ printf "%s-%s" (include "kube-prometheus-stack.fullname" $) "nodes" | trunc 63 | trimSuffix "-" }}
|
||||
annotations:
|
||||
{{ toYaml .Values.grafana.sidecar.dashboards.annotations | indent 4 }}
|
||||
@@ -92,9 +92,8 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "(\n (1 - rate(node_cpu_seconds_total{job=\"node-exporter\", mode=\"idle\", instance=\"$instance\"}[$__interval]))\n/ ignoring(cpu) group_left\n count without (cpu)( node_cpu_seconds_total{job=\"node-exporter\", mode=\"idle\", instance=\"$instance\"})\n)\n",
|
||||
+ "expr": "(\n (1 - rate(node_cpu_seconds_total{job=\"node-exporter\", mode=\"idle\", instance=\"$instance\"}[$__rate_interval]))\n/ ignoring(cpu) group_left\n count without (cpu)( node_cpu_seconds_total{job=\"node-exporter\", mode=\"idle\", instance=\"$instance\"})\n)\n",
|
||||
"format": "time_series",
|
||||
- "interval": "1m",
|
||||
"intervalFactor": 5,
|
||||
"legendFormat": "{{`{{`}}cpu{{`}}`}}",
|
||||
"refId": "A"
|
||||
@@ -528,25 +527,22 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "rate(node_disk_read_bytes_total{job=\"node-exporter\", instance=\"$instance\", device=~\"mmcblk.p.+|nvme.+|rbd.+|sd.+|vd.+|xvd.+|dm-.+|dasd.+\"}[$__interval])",
|
||||
+ "expr": "rate(node_disk_read_bytes_total{job=\"node-exporter\", instance=\"$instance\", device=~\"mmcblk.p.+|nvme.+|rbd.+|sd.+|vd.+|xvd.+|dm-.+|dasd.+\"}[$__rate_interval])",
|
||||
"format": "time_series",
|
||||
- "interval": "1m",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}device{{`}}`}} read",
|
||||
"refId": "A"
|
||||
},
|
||||
{
|
||||
- "expr": "rate(node_disk_written_bytes_total{job=\"node-exporter\", instance=\"$instance\", device=~\"mmcblk.p.+|nvme.+|rbd.+|sd.+|vd.+|xvd.+|dm-.+|dasd.+\"}[$__interval])",
|
||||
+ "expr": "rate(node_disk_written_bytes_total{job=\"node-exporter\", instance=\"$instance\", device=~\"mmcblk.p.+|nvme.+|rbd.+|sd.+|vd.+|xvd.+|dm-.+|dasd.+\"}[$__rate_interval])",
|
||||
"format": "time_series",
|
||||
- "interval": "1m",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}device{{`}}`}} written",
|
||||
"refId": "B"
|
||||
},
|
||||
{
|
||||
- "expr": "rate(node_disk_io_time_seconds_total{job=\"node-exporter\", instance=\"$instance\", device=~\"mmcblk.p.+|nvme.+|rbd.+|sd.+|vd.+|xvd.+|dm-.+|dasd.+\"}[$__interval])",
|
||||
+ "expr": "rate(node_disk_io_time_seconds_total{job=\"node-exporter\", instance=\"$instance\", device=~\"mmcblk.p.+|nvme.+|rbd.+|sd.+|vd.+|xvd.+|dm-.+|dasd.+\"}[$__rate_interval])",
|
||||
"format": "time_series",
|
||||
- "interval": "1m",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}device{{`}}`}} io time",
|
||||
"refId": "C"
|
||||
@@ -758,9 +754,8 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "rate(node_network_receive_bytes_total{job=\"node-exporter\", instance=\"$instance\", device!=\"lo\"}[$__interval])",
|
||||
+ "expr": "rate(node_network_receive_bytes_total{job=\"node-exporter\", instance=\"$instance\", device!=\"lo\"}[$__rate_interval])",
|
||||
"format": "time_series",
|
||||
- "interval": "1m",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}device{{`}}`}}",
|
||||
"refId": "A"
|
||||
@@ -852,9 +847,8 @@
|
||||
"steppedLine": false,
|
||||
"targets": [
|
||||
{
|
||||
- "expr": "rate(node_network_transmit_bytes_total{job=\"node-exporter\", instance=\"$instance\", device!=\"lo\"}[$__interval])",
|
||||
+ "expr": "rate(node_network_transmit_bytes_total{job=\"node-exporter\", instance=\"$instance\", device!=\"lo\"}[$__rate_interval])",
|
||||
"format": "time_series",
|
||||
- "interval": "1m",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}device{{`}}`}}",
|
||||
"refId": "A"
|
||||
@@ -994,4 +988,4 @@
|
||||
"title": "Nodes",
|
||||
"version": 0
|
||||
}
|
||||
-{{- end }}
|
||||
\ No newline at end of file
|
||||
+{{- end }}
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/persistentvolumesusage.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/persistentvolumesusage.yaml
|
||||
@@ -8,7 +8,7 @@
|
||||
@@ -4,11 +4,11 @@
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
@ -14,7 +19,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "(\n sum without(instance, node) (kubelet_volume_stats_capacity_bytes{cluster=\"$cluster\", job=\"kubelet\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})\n -\n sum without(instance, node) (kubelet_volume_stats_available_bytes{cluster=\"$cluster\", job=\"kubelet\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})\n)\n",
|
||||
+ "expr": "(\n sum without(instance, node) (kubelet_volume_stats_capacity_bytes{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})\n -\n sum without(instance, node) (kubelet_volume_stats_available_bytes{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})\n)\n",
|
||||
+ "expr": "(\n sum without(instance, node) (topk(1, (kubelet_volume_stats_capacity_bytes{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})))\n -\n sum without(instance, node) (topk(1, (kubelet_volume_stats_available_bytes{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})))\n)\n",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 1,
|
||||
"legendFormat": "Used Space",
|
||||
|
@ -22,7 +27,7 @@
|
|||
},
|
||||
{
|
||||
- "expr": "sum without(instance, node) (kubelet_volume_stats_available_bytes{cluster=\"$cluster\", job=\"kubelet\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})\n",
|
||||
+ "expr": "sum without(instance, node) (kubelet_volume_stats_available_bytes{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})\n",
|
||||
+ "expr": "sum without(instance, node) (topk(1, (kubelet_volume_stats_available_bytes{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})))\n",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 1,
|
||||
"legendFormat": "Free Space",
|
||||
|
@ -31,7 +36,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "max without(instance,node) (\n(\n kubelet_volume_stats_capacity_bytes{cluster=\"$cluster\", job=\"kubelet\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"}\n -\n kubelet_volume_stats_available_bytes{cluster=\"$cluster\", job=\"kubelet\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"}\n)\n/\nkubelet_volume_stats_capacity_bytes{cluster=\"$cluster\", job=\"kubelet\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"}\n* 100)\n",
|
||||
+ "expr": "max without(instance,node) (\n(\n kubelet_volume_stats_capacity_bytes{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"}\n -\n kubelet_volume_stats_available_bytes{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"}\n)\n/\nkubelet_volume_stats_capacity_bytes{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"}\n* 100)\n",
|
||||
+ "expr": "max without(instance,node) (\n(\n topk(1, kubelet_volume_stats_capacity_bytes{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})\n -\n topk(1, kubelet_volume_stats_available_bytes{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})\n)\n/\ntopk(1, kubelet_volume_stats_capacity_bytes{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})\n* 100)\n",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "",
|
||||
|
@ -40,7 +45,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "sum without(instance, node) (kubelet_volume_stats_inodes_used{cluster=\"$cluster\", job=\"kubelet\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})\n",
|
||||
+ "expr": "sum without(instance, node) (kubelet_volume_stats_inodes_used{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})\n",
|
||||
+ "expr": "sum without(instance, node) (topk(1, (kubelet_volume_stats_inodes_used{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})))\n",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 1,
|
||||
"legendFormat": "Used inodes",
|
||||
|
@ -48,7 +53,7 @@
|
|||
},
|
||||
{
|
||||
- "expr": "(\n sum without(instance, node) (kubelet_volume_stats_inodes{cluster=\"$cluster\", job=\"kubelet\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})\n -\n sum without(instance, node) (kubelet_volume_stats_inodes_used{cluster=\"$cluster\", job=\"kubelet\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})\n)\n",
|
||||
+ "expr": "(\n sum without(instance, node) (kubelet_volume_stats_inodes{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})\n -\n sum without(instance, node) (kubelet_volume_stats_inodes_used{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})\n)\n",
|
||||
+ "expr": "(\n sum without(instance, node) (topk(1, (kubelet_volume_stats_inodes{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})))\n -\n sum without(instance, node) (topk(1, (kubelet_volume_stats_inodes_used{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})))\n)\n",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 1,
|
||||
"legendFormat": " Free inodes",
|
||||
|
@ -57,7 +62,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "max without(instance,node) (\nkubelet_volume_stats_inodes_used{cluster=\"$cluster\", job=\"kubelet\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"}\n/\nkubelet_volume_stats_inodes{cluster=\"$cluster\", job=\"kubelet\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"}\n* 100)\n",
|
||||
+ "expr": "max without(instance,node) (\nkubelet_volume_stats_inodes_used{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"}\n/\nkubelet_volume_stats_inodes{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"}\n* 100)\n",
|
||||
+ "expr": "max without(instance,node) (\ntopk(1, kubelet_volume_stats_inodes_used{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})\n/\ntopk(1, kubelet_volume_stats_inodes{cluster=\"$cluster\", job=\"{{ include "exporter.kubelet.jobName" . }}\", metrics_path=\"/metrics\", namespace=\"$namespace\", persistentvolumeclaim=\"$volume\"})\n* 100)\n",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "",
|
||||
|
@ -79,3 +84,10 @@
|
|||
"refresh": 2,
|
||||
"regex": "",
|
||||
"sort": 1,
|
||||
@@ -574,4 +574,4 @@
|
||||
"uid": "919b92a8e8041bd567af9edab12c840c",
|
||||
"version": 0
|
||||
}
|
||||
-{{- end }}
|
||||
\ No newline at end of file
|
||||
+{{- end }}
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/pod-total.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/pod-total.yaml
|
||||
@@ -8,7 +8,7 @@
|
||||
@@ -4,11 +4,11 @@
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
@ -9,7 +14,7 @@
|
|||
name: {{ printf "%s-%s" (include "kube-prometheus-stack.fullname" $) "pod-total" | trunc 63 | trimSuffix "-" }}
|
||||
annotations:
|
||||
{{ toYaml .Values.grafana.sidecar.dashboards.annotations | indent 4 }}
|
||||
@@ -1027,7 +1027,7 @@
|
||||
@@ -1027,14 +1027,14 @@
|
||||
"datasource": "$datasource",
|
||||
"hide": {{ if .Values.grafana.sidecar.dashboards.multicluster }}0{{ else }}2{{ end }},
|
||||
"includeAll": false,
|
||||
|
@ -18,6 +23,32 @@
|
|||
"multi": false,
|
||||
"name": "cluster",
|
||||
"options": [
|
||||
|
||||
],
|
||||
"query": "label_values(kube_pod_info, cluster)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"sort": 0,
|
||||
"tagValuesQuery": "",
|
||||
@@ -1065,7 +1065,7 @@
|
||||
|
||||
],
|
||||
"query": "label_values(container_network_receive_packets_total{cluster=\"$cluster\"}, namespace)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"skipUrlSync": false,
|
||||
"sort": 1,
|
||||
@@ -1097,7 +1097,7 @@
|
||||
|
||||
],
|
||||
"query": "label_values(container_network_receive_packets_total{cluster=\"$cluster\",namespace=~\"$namespace\"}, pod)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"skipUrlSync": false,
|
||||
"sort": 1,
|
||||
@@ -1225,4 +1225,4 @@
|
||||
"uid": "7a18067ce943a40ae25454675c19ff5c",
|
||||
"version": 0
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/prometheus-remote-write.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/prometheus-remote-write.yaml
|
||||
@@ -8,7 +8,7 @@
|
||||
@@ -4,11 +4,11 @@
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled .Values.prometheus.prometheusSpec.remoteWriteDashboards }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled .Values.prometheus.prometheusSpec.remoteWriteDashboards }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
@ -9,3 +14,10 @@
|
|||
name: {{ printf "%s-%s" (include "kube-prometheus-stack.fullname" $) "prometheus-remote-write" | trunc 63 | trimSuffix "-" }}
|
||||
annotations:
|
||||
{{ toYaml .Values.grafana.sidecar.dashboards.annotations | indent 4 }}
|
||||
@@ -1667,4 +1667,4 @@
|
||||
"title": "Prometheus / Remote Write",
|
||||
"version": 0
|
||||
}
|
||||
-{{- end }}
|
||||
\ No newline at end of file
|
||||
+{{- end }}
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/prometheus.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/prometheus.yaml
|
||||
@@ -8,7 +8,7 @@
|
||||
@@ -4,11 +4,11 @@
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
@ -9,3 +14,118 @@
|
|||
name: {{ printf "%s-%s" (include "kube-prometheus-stack.fullname" $) "prometheus" | trunc 63 | trimSuffix "-" }}
|
||||
annotations:
|
||||
{{ toYaml .Values.grafana.sidecar.dashboards.annotations | indent 4 }}
|
||||
@@ -220,7 +220,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Prometheus Stats",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -319,7 +319,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Target Sync",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -405,7 +405,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Targets",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -503,7 +503,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Average Scrape Interval Duration",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -613,7 +613,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Scrape failures",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -699,7 +699,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Appended Samples",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -797,7 +797,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Head Series",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -883,7 +883,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Head Chunks",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -981,7 +981,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Query Rate",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -1067,7 +1067,7 @@
|
||||
"timeShift": null,
|
||||
"title": "Stage Duration",
|
||||
"tooltip": {
|
||||
- "shared": true,
|
||||
+ "shared": false,
|
||||
"sort": 0,
|
||||
"value_type": "individual"
|
||||
},
|
||||
@@ -1133,7 +1133,7 @@
|
||||
"type": "datasource"
|
||||
},
|
||||
{
|
||||
- "allValue": null,
|
||||
+ "allValue": ".+",
|
||||
"current": {
|
||||
"selected": true,
|
||||
"text": "All",
|
||||
@@ -1161,7 +1161,7 @@
|
||||
"useTags": false
|
||||
},
|
||||
{
|
||||
- "allValue": null,
|
||||
+ "allValue": ".+",
|
||||
"current": {
|
||||
"selected": true,
|
||||
"text": "All",
|
||||
@@ -1224,4 +1224,4 @@
|
||||
"uid": "",
|
||||
"version": 0
|
||||
}
|
||||
-{{- end }}
|
||||
\ No newline at end of file
|
||||
+{{- end }}
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled .Values.kubeProxy.enabled }}
|
||||
+{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if (include "exporter.kubeProxy.enabled" .)}}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
|
@ -21,9 +21,9 @@
|
|||
{
|
||||
- "expr": "sum(up{job=\"kube-proxy\"})",
|
||||
+ {{- if .Values.k3sServer.enabled }}
|
||||
+ "expr": "sum(up{job=\"{{ include "exporter.kubeProxy.jobName" . }}\", metrics_path=\"/metrics\"})",
|
||||
+ "expr": "sum(up{cluster=\"$cluster\", job=\"{{ include "exporter.kubeProxy.jobName" . }}\", metrics_path=\"/metrics\"})",
|
||||
+ {{- else }}
|
||||
+ "expr": "sum(up{job=\"{{ include "exporter.kubeProxy.jobName" . }}\"})",
|
||||
+ "expr": "sum(up{cluster=\"$cluster\", job=\"{{ include "exporter.kubeProxy.jobName" . }}\"})",
|
||||
+ {{- end }}
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
|
@ -33,7 +33,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "sum(rate(kubeproxy_sync_proxy_rules_duration_seconds_count{job=\"kube-proxy\", instance=~\"$instance\"}[5m]))",
|
||||
+ "expr": "sum(rate(kubeproxy_sync_proxy_rules_duration_seconds_count{job=\"{{ include "exporter.kubeProxy.jobName" . }}\", instance=~\"$instance\"}[5m]))",
|
||||
+ "expr": "sum(rate(kubeproxy_sync_proxy_rules_duration_seconds_count{cluster=\"$cluster\", job=\"{{ include "exporter.kubeProxy.jobName" . }}\", instance=~\"$instance\"}[5m]))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "rate",
|
||||
|
@ -42,7 +42,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "histogram_quantile(0.99,rate(kubeproxy_sync_proxy_rules_duration_seconds_bucket{job=\"kube-proxy\", instance=~\"$instance\"}[5m]))",
|
||||
+ "expr": "histogram_quantile(0.99,rate(kubeproxy_sync_proxy_rules_duration_seconds_bucket{job=\"{{ include "exporter.kubeProxy.jobName" . }}\", instance=~\"$instance\"}[5m]))",
|
||||
+ "expr": "histogram_quantile(0.99,rate(kubeproxy_sync_proxy_rules_duration_seconds_bucket{cluster=\"$cluster\", job=\"{{ include "exporter.kubeProxy.jobName" . }}\", instance=~\"$instance\"}[5m]))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}}",
|
||||
|
@ -51,7 +51,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "sum(rate(kubeproxy_network_programming_duration_seconds_count{job=\"kube-proxy\", instance=~\"$instance\"}[5m]))",
|
||||
+ "expr": "sum(rate(kubeproxy_network_programming_duration_seconds_count{job=\"{{ include "exporter.kubeProxy.jobName" . }}\", instance=~\"$instance\"}[5m]))",
|
||||
+ "expr": "sum(rate(kubeproxy_network_programming_duration_seconds_count{cluster=\"$cluster\", job=\"{{ include "exporter.kubeProxy.jobName" . }}\", instance=~\"$instance\"}[5m]))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "rate",
|
||||
|
@ -60,7 +60,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "histogram_quantile(0.99, sum(rate(kubeproxy_network_programming_duration_seconds_bucket{job=\"kube-proxy\", instance=~\"$instance\"}[5m])) by (instance, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(kubeproxy_network_programming_duration_seconds_bucket{job=\"{{ include "exporter.kubeProxy.jobName" . }}\", instance=~\"$instance\"}[5m])) by (instance, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(kubeproxy_network_programming_duration_seconds_bucket{cluster=\"$cluster\", job=\"{{ include "exporter.kubeProxy.jobName" . }}\", instance=~\"$instance\"}[5m])) by (instance, le))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}}",
|
||||
|
@ -69,7 +69,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "sum(rate(rest_client_requests_total{job=\"kube-proxy\", instance=~\"$instance\",code=~\"2..\"}[5m]))",
|
||||
+ "expr": "sum(rate(rest_client_requests_total{job=\"{{ include "exporter.kubeProxy.jobName" . }}\", instance=~\"$instance\",code=~\"2..\"}[5m]))",
|
||||
+ "expr": "sum(rate(rest_client_requests_total{cluster=\"$cluster\", job=\"{{ include "exporter.kubeProxy.jobName" . }}\", instance=~\"$instance\",code=~\"2..\"}[5m]))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "2xx",
|
||||
|
@ -77,7 +77,7 @@
|
|||
},
|
||||
{
|
||||
- "expr": "sum(rate(rest_client_requests_total{job=\"kube-proxy\", instance=~\"$instance\",code=~\"3..\"}[5m]))",
|
||||
+ "expr": "sum(rate(rest_client_requests_total{job=\"{{ include "exporter.kubeProxy.jobName" . }}\", instance=~\"$instance\",code=~\"3..\"}[5m]))",
|
||||
+ "expr": "sum(rate(rest_client_requests_total{cluster=\"$cluster\", job=\"{{ include "exporter.kubeProxy.jobName" . }}\", instance=~\"$instance\",code=~\"3..\"}[5m]))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "3xx",
|
||||
|
@ -85,7 +85,7 @@
|
|||
},
|
||||
{
|
||||
- "expr": "sum(rate(rest_client_requests_total{job=\"kube-proxy\", instance=~\"$instance\",code=~\"4..\"}[5m]))",
|
||||
+ "expr": "sum(rate(rest_client_requests_total{job=\"{{ include "exporter.kubeProxy.jobName" . }}\", instance=~\"$instance\",code=~\"4..\"}[5m]))",
|
||||
+ "expr": "sum(rate(rest_client_requests_total{cluster=\"$cluster\", job=\"{{ include "exporter.kubeProxy.jobName" . }}\", instance=~\"$instance\",code=~\"4..\"}[5m]))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "4xx",
|
||||
|
@ -93,7 +93,7 @@
|
|||
},
|
||||
{
|
||||
- "expr": "sum(rate(rest_client_requests_total{job=\"kube-proxy\", instance=~\"$instance\",code=~\"5..\"}[5m]))",
|
||||
+ "expr": "sum(rate(rest_client_requests_total{job=\"{{ include "exporter.kubeProxy.jobName" . }}\", instance=~\"$instance\",code=~\"5..\"}[5m]))",
|
||||
+ "expr": "sum(rate(rest_client_requests_total{cluster=\"$cluster\", job=\"{{ include "exporter.kubeProxy.jobName" . }}\", instance=~\"$instance\",code=~\"5..\"}[5m]))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "5xx",
|
||||
|
@ -102,7 +102,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "histogram_quantile(0.99, sum(rate(rest_client_request_duration_seconds_bucket{job=\"kube-proxy\",instance=~\"$instance\",verb=\"POST\"}[5m])) by (verb, url, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(rest_client_request_duration_seconds_bucket{job=\"{{ include "exporter.kubeProxy.jobName" . }}\",instance=~\"$instance\",verb=\"POST\"}[5m])) by (verb, url, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(rest_client_request_duration_seconds_bucket{cluster=\"$cluster\", job=\"{{ include "exporter.kubeProxy.jobName" . }}\",instance=~\"$instance\",verb=\"POST\"}[5m])) by (verb, url, le))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}verb{{`}}`}} {{`{{`}}url{{`}}`}}",
|
||||
|
@ -111,7 +111,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "histogram_quantile(0.99, sum(rate(rest_client_request_duration_seconds_bucket{job=\"kube-proxy\", instance=~\"$instance\", verb=\"GET\"}[5m])) by (verb, url, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(rest_client_request_duration_seconds_bucket{job=\"{{ include "exporter.kubeProxy.jobName" . }}\", instance=~\"$instance\", verb=\"GET\"}[5m])) by (verb, url, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(rest_client_request_duration_seconds_bucket{cluster=\"$cluster\", job=\"{{ include "exporter.kubeProxy.jobName" . }}\", instance=~\"$instance\", verb=\"GET\"}[5m])) by (verb, url, le))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}verb{{`}}`}} {{`{{`}}url{{`}}`}}",
|
||||
|
@ -120,7 +120,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "process_resident_memory_bytes{job=\"kube-proxy\",instance=~\"$instance\"}",
|
||||
+ "expr": "process_resident_memory_bytes{job=\"{{ include "exporter.kubeProxy.jobName" . }}\",instance=~\"$instance\"}",
|
||||
+ "expr": "process_resident_memory_bytes{cluster=\"$cluster\", job=\"{{ include "exporter.kubeProxy.jobName" . }}\",instance=~\"$instance\"}",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}}",
|
||||
|
@ -129,7 +129,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "rate(process_cpu_seconds_total{job=\"kube-proxy\",instance=~\"$instance\"}[5m])",
|
||||
+ "expr": "rate(process_cpu_seconds_total{job=\"{{ include "exporter.kubeProxy.jobName" . }}\",instance=~\"$instance\"}[5m])",
|
||||
+ "expr": "rate(process_cpu_seconds_total{cluster=\"$cluster\", job=\"{{ include "exporter.kubeProxy.jobName" . }}\",instance=~\"$instance\"}[5m])",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}}",
|
||||
|
@ -138,24 +138,56 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "go_goroutines{job=\"kube-proxy\",instance=~\"$instance\"}",
|
||||
+ "expr": "go_goroutines{job=\"{{ include "exporter.kubeProxy.jobName" . }}\",instance=~\"$instance\"}",
|
||||
+ "expr": "go_goroutines{cluster=\"$cluster\", job=\"{{ include "exporter.kubeProxy.jobName" . }}\",instance=~\"$instance\"}",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}}",
|
||||
@@ -1180,7 +1185,7 @@
|
||||
@@ -1172,6 +1177,32 @@
|
||||
|
||||
},
|
||||
"datasource": "$datasource",
|
||||
+ "hide": {{ if .Values.grafana.sidecar.dashboards.multicluster }}0{{ else }}2{{ end }},
|
||||
+ "includeAll": false,
|
||||
+ "label": "cluster",
|
||||
+ "multi": false,
|
||||
+ "name": "cluster",
|
||||
+ "options": [
|
||||
+
|
||||
+ ],
|
||||
+ "query": "label_values(kube_pod_info, cluster)",
|
||||
+ "refresh": 2,
|
||||
+ "regex": "",
|
||||
+ "sort": 1,
|
||||
+ "tagValuesQuery": "",
|
||||
+ "tags": [
|
||||
+
|
||||
+ ],
|
||||
+ "tagsQuery": "",
|
||||
+ "type": "query",
|
||||
+ "useTags": false
|
||||
+ },
|
||||
+ {
|
||||
+ "allValue": null,
|
||||
+ "current": {
|
||||
+
|
||||
+ },
|
||||
+ "datasource": "$datasource",
|
||||
"hide": 0,
|
||||
"includeAll": true,
|
||||
"label": null,
|
||||
@@ -1180,7 +1211,7 @@
|
||||
"options": [
|
||||
|
||||
],
|
||||
- "query": "label_values(kubeproxy_network_programming_duration_seconds_bucket{job=\"kube-proxy\"}, instance)",
|
||||
+ "query": "label_values(kubeproxy_network_programming_duration_seconds_bucket{job=\"{{ include "exporter.kubeProxy.jobName" . }}\"}, instance)",
|
||||
+ "query": "label_values(kubeproxy_network_programming_duration_seconds_bucket{cluster=\"$cluster\", job=\"{{ include "exporter.kubeProxy.jobName" . }}\"}, instance)",
|
||||
"refresh": 2,
|
||||
"regex": "",
|
||||
"sort": 1,
|
||||
@@ -1228,4 +1233,4 @@
|
||||
@@ -1228,4 +1259,4 @@
|
||||
"uid": "632e265de029684c40b21cb76bca4f94",
|
||||
"version": 0
|
||||
}
|
||||
-{{- end }}
|
||||
\ No newline at end of file
|
||||
+{{- end }}{{- end }}
|
||||
\ No newline at end of file
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled .Values.kubeScheduler.enabled }}
|
||||
+{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if (include "exporter.kubeScheduler.enabled" .)}}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
|
@ -21,9 +21,9 @@
|
|||
{
|
||||
- "expr": "sum(up{job=\"kube-scheduler\"})",
|
||||
+ {{- if .Values.k3sServer.enabled }}
|
||||
+ "expr": "sum(up{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", metrics_path=\"/metrics\"})",
|
||||
+ "expr": "sum(up{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", metrics_path=\"/metrics\"})",
|
||||
+ {{- else }}
|
||||
+ "expr": "sum(up{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\"})",
|
||||
+ "expr": "sum(up{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\"})",
|
||||
+ {{- end }}
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
|
@ -33,7 +33,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "sum(rate(scheduler_e2e_scheduling_duration_seconds_count{job=\"kube-scheduler\", instance=~\"$instance\"}[5m])) by (instance)",
|
||||
+ "expr": "sum(rate(scheduler_e2e_scheduling_duration_seconds_count{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\"}[5m])) by (instance)",
|
||||
+ "expr": "sum(rate(scheduler_e2e_scheduling_duration_seconds_count{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\"}[5m])) by (instance)",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}} e2e",
|
||||
|
@ -41,7 +41,7 @@
|
|||
},
|
||||
{
|
||||
- "expr": "sum(rate(scheduler_binding_duration_seconds_count{job=\"kube-scheduler\", instance=~\"$instance\"}[5m])) by (instance)",
|
||||
+ "expr": "sum(rate(scheduler_binding_duration_seconds_count{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\"}[5m])) by (instance)",
|
||||
+ "expr": "sum(rate(scheduler_binding_duration_seconds_count{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\"}[5m])) by (instance)",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}} binding",
|
||||
|
@ -49,7 +49,7 @@
|
|||
},
|
||||
{
|
||||
- "expr": "sum(rate(scheduler_scheduling_algorithm_duration_seconds_count{job=\"kube-scheduler\", instance=~\"$instance\"}[5m])) by (instance)",
|
||||
+ "expr": "sum(rate(scheduler_scheduling_algorithm_duration_seconds_count{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\"}[5m])) by (instance)",
|
||||
+ "expr": "sum(rate(scheduler_scheduling_algorithm_duration_seconds_count{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\"}[5m])) by (instance)",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}} scheduling algorithm",
|
||||
|
@ -57,7 +57,7 @@
|
|||
},
|
||||
{
|
||||
- "expr": "sum(rate(scheduler_volume_scheduling_duration_seconds_count{job=\"kube-scheduler\", instance=~\"$instance\"}[5m])) by (instance)",
|
||||
+ "expr": "sum(rate(scheduler_volume_scheduling_duration_seconds_count{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\"}[5m])) by (instance)",
|
||||
+ "expr": "sum(rate(scheduler_volume_scheduling_duration_seconds_count{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\"}[5m])) by (instance)",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}} volume",
|
||||
|
@ -66,7 +66,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "histogram_quantile(0.99, sum(rate(scheduler_e2e_scheduling_duration_seconds_bucket{job=\"kube-scheduler\",instance=~\"$instance\"}[5m])) by (instance, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(scheduler_e2e_scheduling_duration_seconds_bucket{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\",instance=~\"$instance\"}[5m])) by (instance, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(scheduler_e2e_scheduling_duration_seconds_bucket{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\",instance=~\"$instance\"}[5m])) by (instance, le))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}} e2e",
|
||||
|
@ -74,7 +74,7 @@
|
|||
},
|
||||
{
|
||||
- "expr": "histogram_quantile(0.99, sum(rate(scheduler_binding_duration_seconds_bucket{job=\"kube-scheduler\",instance=~\"$instance\"}[5m])) by (instance, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(scheduler_binding_duration_seconds_bucket{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\",instance=~\"$instance\"}[5m])) by (instance, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(scheduler_binding_duration_seconds_bucket{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\",instance=~\"$instance\"}[5m])) by (instance, le))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}} binding",
|
||||
|
@ -82,7 +82,7 @@
|
|||
},
|
||||
{
|
||||
- "expr": "histogram_quantile(0.99, sum(rate(scheduler_scheduling_algorithm_duration_seconds_bucket{job=\"kube-scheduler\",instance=~\"$instance\"}[5m])) by (instance, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(scheduler_scheduling_algorithm_duration_seconds_bucket{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\",instance=~\"$instance\"}[5m])) by (instance, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(scheduler_scheduling_algorithm_duration_seconds_bucket{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\",instance=~\"$instance\"}[5m])) by (instance, le))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}} scheduling algorithm",
|
||||
|
@ -90,7 +90,7 @@
|
|||
},
|
||||
{
|
||||
- "expr": "histogram_quantile(0.99, sum(rate(scheduler_volume_scheduling_duration_seconds_bucket{job=\"kube-scheduler\",instance=~\"$instance\"}[5m])) by (instance, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(scheduler_volume_scheduling_duration_seconds_bucket{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\",instance=~\"$instance\"}[5m])) by (instance, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(scheduler_volume_scheduling_duration_seconds_bucket{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\",instance=~\"$instance\"}[5m])) by (instance, le))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}} volume",
|
||||
|
@ -99,7 +99,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "sum(rate(rest_client_requests_total{job=\"kube-scheduler\", instance=~\"$instance\",code=~\"2..\"}[5m]))",
|
||||
+ "expr": "sum(rate(rest_client_requests_total{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\",code=~\"2..\"}[5m]))",
|
||||
+ "expr": "sum(rate(rest_client_requests_total{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\",code=~\"2..\"}[5m]))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "2xx",
|
||||
|
@ -107,7 +107,7 @@
|
|||
},
|
||||
{
|
||||
- "expr": "sum(rate(rest_client_requests_total{job=\"kube-scheduler\", instance=~\"$instance\",code=~\"3..\"}[5m]))",
|
||||
+ "expr": "sum(rate(rest_client_requests_total{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\",code=~\"3..\"}[5m]))",
|
||||
+ "expr": "sum(rate(rest_client_requests_total{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\",code=~\"3..\"}[5m]))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "3xx",
|
||||
|
@ -115,7 +115,7 @@
|
|||
},
|
||||
{
|
||||
- "expr": "sum(rate(rest_client_requests_total{job=\"kube-scheduler\", instance=~\"$instance\",code=~\"4..\"}[5m]))",
|
||||
+ "expr": "sum(rate(rest_client_requests_total{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\",code=~\"4..\"}[5m]))",
|
||||
+ "expr": "sum(rate(rest_client_requests_total{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\",code=~\"4..\"}[5m]))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "4xx",
|
||||
|
@ -123,7 +123,7 @@
|
|||
},
|
||||
{
|
||||
- "expr": "sum(rate(rest_client_requests_total{job=\"kube-scheduler\", instance=~\"$instance\",code=~\"5..\"}[5m]))",
|
||||
+ "expr": "sum(rate(rest_client_requests_total{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\",code=~\"5..\"}[5m]))",
|
||||
+ "expr": "sum(rate(rest_client_requests_total{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\",code=~\"5..\"}[5m]))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "5xx",
|
||||
|
@ -132,7 +132,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "histogram_quantile(0.99, sum(rate(rest_client_request_duration_seconds_bucket{job=\"kube-scheduler\", instance=~\"$instance\", verb=\"POST\"}[5m])) by (verb, url, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(rest_client_request_duration_seconds_bucket{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\", verb=\"POST\"}[5m])) by (verb, url, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(rest_client_request_duration_seconds_bucket{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\", verb=\"POST\"}[5m])) by (verb, url, le))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}verb{{`}}`}} {{`{{`}}url{{`}}`}}",
|
||||
|
@ -141,7 +141,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "histogram_quantile(0.99, sum(rate(rest_client_request_duration_seconds_bucket{job=\"kube-scheduler\", instance=~\"$instance\", verb=\"GET\"}[5m])) by (verb, url, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(rest_client_request_duration_seconds_bucket{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\", verb=\"GET\"}[5m])) by (verb, url, le))",
|
||||
+ "expr": "histogram_quantile(0.99, sum(rate(rest_client_request_duration_seconds_bucket{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\", verb=\"GET\"}[5m])) by (verb, url, le))",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}verb{{`}}`}} {{`{{`}}url{{`}}`}}",
|
||||
|
@ -150,7 +150,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "process_resident_memory_bytes{job=\"kube-scheduler\", instance=~\"$instance\"}",
|
||||
+ "expr": "process_resident_memory_bytes{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\"}",
|
||||
+ "expr": "process_resident_memory_bytes{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\"}",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}}",
|
||||
|
@ -159,7 +159,7 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "rate(process_cpu_seconds_total{job=\"kube-scheduler\", instance=~\"$instance\"}[5m])",
|
||||
+ "expr": "rate(process_cpu_seconds_total{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\"}[5m])",
|
||||
+ "expr": "rate(process_cpu_seconds_total{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\", instance=~\"$instance\"}[5m])",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}}",
|
||||
|
@ -168,23 +168,57 @@
|
|||
"targets": [
|
||||
{
|
||||
- "expr": "go_goroutines{job=\"kube-scheduler\",instance=~\"$instance\"}",
|
||||
+ "expr": "go_goroutines{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\",instance=~\"$instance\"}",
|
||||
+ "expr": "go_goroutines{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\",instance=~\"$instance\"}",
|
||||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "{{`{{`}}instance{{`}}`}}",
|
||||
@@ -1023,7 +1028,7 @@
|
||||
@@ -1015,6 +1020,32 @@
|
||||
|
||||
},
|
||||
"datasource": "$datasource",
|
||||
+ "hide": {{ if .Values.grafana.sidecar.dashboards.multicluster }}0{{ else }}2{{ end }},
|
||||
+ "includeAll": false,
|
||||
+ "label": "cluster",
|
||||
+ "multi": false,
|
||||
+ "name": "cluster",
|
||||
+ "options": [
|
||||
+
|
||||
+ ],
|
||||
+ "query": "label_values(kube_pod_info, cluster)",
|
||||
+ "refresh": 2,
|
||||
+ "regex": "",
|
||||
+ "sort": 1,
|
||||
+ "tagValuesQuery": "",
|
||||
+ "tags": [
|
||||
+
|
||||
+ ],
|
||||
+ "tagsQuery": "",
|
||||
+ "type": "query",
|
||||
+ "useTags": false
|
||||
+ },
|
||||
+ {
|
||||
+ "allValue": null,
|
||||
+ "current": {
|
||||
+
|
||||
+ },
|
||||
+ "datasource": "$datasource",
|
||||
"hide": 0,
|
||||
"includeAll": true,
|
||||
"label": null,
|
||||
@@ -1023,7 +1054,7 @@
|
||||
"options": [
|
||||
|
||||
],
|
||||
- "query": "label_values(process_cpu_seconds_total{job=\"kube-scheduler\"}, instance)",
|
||||
+ "query": "label_values(process_cpu_seconds_total{job=\"{{ include "exporter.kubeScheduler.jobName" . }}\"}, instance)",
|
||||
+ "query": "label_values(process_cpu_seconds_total{cluster=\"$cluster\", job=\"{{ include "exporter.kubeScheduler.jobName" . }}\"}, instance)",
|
||||
"refresh": 2,
|
||||
"regex": "",
|
||||
"sort": 1,
|
||||
@@ -1071,4 +1076,5 @@
|
||||
@@ -1071,4 +1102,5 @@
|
||||
"uid": "2e6b6a3b4bddf1427b3a55aa1311c656",
|
||||
"version": 0
|
||||
}
|
||||
+{{- end }}
|
||||
{{- end }}
|
||||
-{{- end }}
|
||||
\ No newline at end of file
|
||||
+{{- end }}
|
||||
+{{- end }}
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/statefulset.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/statefulset.yaml
|
||||
@@ -8,7 +8,7 @@
|
||||
@@ -4,11 +4,11 @@
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
@ -36,3 +41,10 @@
|
|||
"format": "time_series",
|
||||
"intervalFactor": 2,
|
||||
"legendFormat": "",
|
||||
@@ -925,4 +925,4 @@
|
||||
"uid": "a31c1f46e6f727cb37c0d731a7245005",
|
||||
"version": 0
|
||||
}
|
||||
-{{- end }}
|
||||
\ No newline at end of file
|
||||
+{{- end }}
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
--- charts-original/templates/grafana/dashboards-1.14/workload-total.yaml
|
||||
+++ charts/templates/grafana/dashboards-1.14/workload-total.yaml
|
||||
@@ -8,7 +8,7 @@
|
||||
@@ -4,11 +4,11 @@
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
-{{- if and (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.enabled .Values.grafana.defaultDashboardsEnabled }}
|
||||
+{{- if and (or .Values.grafana.enabled .Values.grafana.forceDeployDashboards) (semverCompare ">=1.14.0-0" $kubeTargetVersion) (semverCompare "<9.9.9-9" $kubeTargetVersion) .Values.grafana.defaultDashboardsEnabled }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
|
@ -9,7 +14,7 @@
|
|||
name: {{ printf "%s-%s" (include "kube-prometheus-stack.fullname" $) "workload-total" | trunc 63 | trimSuffix "-" }}
|
||||
annotations:
|
||||
{{ toYaml .Values.grafana.sidecar.dashboards.annotations | indent 4 }}
|
||||
@@ -1205,7 +1205,7 @@
|
||||
@@ -1205,14 +1205,14 @@
|
||||
"datasource": "$datasource",
|
||||
"hide": {{ if .Values.grafana.sidecar.dashboards.multicluster }}0{{ else }}2{{ end }},
|
||||
"includeAll": false,
|
||||
|
@ -18,6 +23,41 @@
|
|||
"multi": false,
|
||||
"name": "cluster",
|
||||
"options": [
|
||||
|
||||
],
|
||||
"query": "label_values(kube_pod_info, cluster)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"sort": 0,
|
||||
"tagValuesQuery": "",
|
||||
@@ -1243,7 +1243,7 @@
|
||||
|
||||
],
|
||||
"query": "label_values(container_network_receive_packets_total{cluster=\"$cluster\"}, namespace)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"skipUrlSync": false,
|
||||
"sort": 1,
|
||||
@@ -1275,7 +1275,7 @@
|
||||
|
||||
],
|
||||
"query": "label_values(namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\",namespace=~\"$namespace\"}, workload)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"skipUrlSync": false,
|
||||
"sort": 1,
|
||||
@@ -1307,7 +1307,7 @@
|
||||
|
||||
],
|
||||
"query": "label_values(namespace_workload_pod:kube_pod_owner:relabel{cluster=\"$cluster\",namespace=~\"$namespace\", workload=~\"$workload\"}, workload_type)",
|
||||
- "refresh": 1,
|
||||
+ "refresh": 2,
|
||||
"regex": "",
|
||||
"skipUrlSync": false,
|
||||
"sort": 0,
|
||||
@@ -1435,4 +1435,4 @@
|
||||
"uid": "728bf77cc1166d2f3133bf25846876cc",
|
||||
"version": 0
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
{{- end }}
|
||||
imagePullPolicy: {{ .Values.prometheusOperator.admissionWebhooks.patch.image.pullPolicy }}
|
||||
args:
|
||||
@@ -46,18 +46,18 @@
|
||||
@@ -46,20 +46,20 @@
|
||||
{{ toYaml .Values.prometheusOperator.admissionWebhooks.patch.resources | indent 12 }}
|
||||
restartPolicy: OnFailure
|
||||
serviceAccountName: {{ template "kube-prometheus-stack.fullname" . }}-admission
|
||||
|
@ -32,8 +32,12 @@
|
|||
+ tolerations: {{ include "linux-node-tolerations" . | nindent 8 }}
|
||||
+{{- with .Values.prometheusOperator.admissionWebhooks.patch.tolerations }}
|
||||
{{ toYaml . | indent 8 }}
|
||||
- {{- end }}
|
||||
+{{- end }}
|
||||
{{- end }}
|
||||
+{{- if .Values.prometheusOperator.admissionWebhooks.patch.securityContext }}
|
||||
securityContext:
|
||||
runAsGroup: 2000
|
||||
runAsNonRoot: true
|
||||
- runAsGroup: 2000
|
||||
- runAsNonRoot: true
|
||||
- runAsUser: 2000
|
||||
+{{ toYaml .Values.prometheusOperator.admissionWebhooks.patch.securityContext | indent 8 }}
|
||||
+{{- end }}
|
||||
{{- end }}
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
{{- end }}
|
||||
imagePullPolicy: {{ .Values.prometheusOperator.admissionWebhooks.patch.image.pullPolicy }}
|
||||
args:
|
||||
@@ -47,18 +47,18 @@
|
||||
@@ -47,20 +47,20 @@
|
||||
{{ toYaml .Values.prometheusOperator.admissionWebhooks.patch.resources | indent 12 }}
|
||||
restartPolicy: OnFailure
|
||||
serviceAccountName: {{ template "kube-prometheus-stack.fullname" . }}-admission
|
||||
|
@ -32,8 +32,12 @@
|
|||
+ tolerations: {{ include "linux-node-tolerations" . | nindent 8 }}
|
||||
+{{- with .Values.prometheusOperator.admissionWebhooks.patch.tolerations }}
|
||||
{{ toYaml . | indent 8 }}
|
||||
- {{- end }}
|
||||
+{{- end }}
|
||||
{{- end }}
|
||||
+{{- if .Values.prometheusOperator.admissionWebhooks.patch.securityContext }}
|
||||
securityContext:
|
||||
runAsGroup: 2000
|
||||
runAsNonRoot: true
|
||||
- runAsGroup: 2000
|
||||
- runAsNonRoot: true
|
||||
- runAsUser: 2000
|
||||
+{{ toYaml .Values.prometheusOperator.admissionWebhooks.patch.securityContext | indent 8 }}
|
||||
+{{- end }}
|
||||
{{- end }}
|
||||
|
|
|
@ -0,0 +1,11 @@
|
|||
--- charts-original/templates/prometheus-operator/admission-webhooks/job-patch/serviceaccount.yaml
|
||||
+++ charts/templates/prometheus-operator/admission-webhooks/job-patch/serviceaccount.yaml
|
||||
@@ -10,6 +10,8 @@
|
||||
labels:
|
||||
app: {{ template "kube-prometheus-stack.name" $ }}-admission
|
||||
{{- include "kube-prometheus-stack.labels" $ | indent 4 }}
|
||||
+{{- if .Values.global.imagePullSecrets }}
|
||||
imagePullSecrets:
|
||||
{{ toYaml .Values.global.imagePullSecrets | indent 2 }}
|
||||
{{- end }}
|
||||
+{{- end }}
|
|
@ -0,0 +1,13 @@
|
|||
--- charts-original/templates/prometheus-operator/admission-webhooks/mutatingWebhookConfiguration.yaml
|
||||
+++ charts/templates/prometheus-operator/admission-webhooks/mutatingWebhookConfiguration.yaml
|
||||
@@ -5,8 +5,8 @@
|
||||
name: {{ template "kube-prometheus-stack.fullname" . }}-admission
|
||||
{{- if .Values.prometheusOperator.admissionWebhooks.certManager.enabled }}
|
||||
annotations:
|
||||
- certmanager.k8s.io/inject-ca-from: {{ printf "%s/%s-root-cert" .Release.Namespace (include "kube-prometheus-stack.fullname" .) | quote }}
|
||||
- cert-manager.io/inject-ca-from: {{ printf "%s/%s-root-cert" .Release.Namespace (include "kube-prometheus-stack.fullname" .) | quote }}
|
||||
+ certmanager.k8s.io/inject-ca-from: {{ printf "%s/%s-admission" .Release.Namespace (include "kube-prometheus-stack.fullname" .) | quote }}
|
||||
+ cert-manager.io/inject-ca-from: {{ printf "%s/%s-admission" .Release.Namespace (include "kube-prometheus-stack.fullname" .) | quote }}
|
||||
{{- end }}
|
||||
labels:
|
||||
app: {{ template "kube-prometheus-stack.name" $ }}-admission
|
|
@ -0,0 +1,13 @@
|
|||
--- charts-original/templates/prometheus-operator/admission-webhooks/validatingWebhookConfiguration.yaml
|
||||
+++ charts/templates/prometheus-operator/admission-webhooks/validatingWebhookConfiguration.yaml
|
||||
@@ -5,8 +5,8 @@
|
||||
name: {{ template "kube-prometheus-stack.fullname" . }}-admission
|
||||
{{- if .Values.prometheusOperator.admissionWebhooks.certManager.enabled }}
|
||||
annotations:
|
||||
- certmanager.k8s.io/inject-ca-from: {{ printf "%s/%s-root-cert" .Release.Namespace (include "kube-prometheus-stack.fullname" .) | quote }}
|
||||
- cert-manager.io/inject-ca-from: {{ printf "%s/%s-root-cert" .Release.Namespace (include "kube-prometheus-stack.fullname" .) | quote }}
|
||||
+ certmanager.k8s.io/inject-ca-from: {{ printf "%s/%s-admission" .Release.Namespace (include "kube-prometheus-stack.fullname" .) | quote }}
|
||||
+ cert-manager.io/inject-ca-from: {{ printf "%s/%s-admission" .Release.Namespace (include "kube-prometheus-stack.fullname" .) | quote }}
|
||||
{{- end }}
|
||||
labels:
|
||||
app: {{ template "kube-prometheus-stack.name" $ }}-admission
|
|
@ -0,0 +1,20 @@
|
|||
--- charts-original/templates/prometheus-operator/certmanager.yaml
|
||||
+++ charts/templates/prometheus-operator/certmanager.yaml
|
||||
@@ -18,7 +18,7 @@
|
||||
namespace: {{ template "kube-prometheus-stack.namespace" . }}
|
||||
spec:
|
||||
secretName: {{ template "kube-prometheus-stack.fullname" . }}-root-cert
|
||||
- duration: 43800h # 5y
|
||||
+ duration: 43800h0m0s # 5y
|
||||
issuerRef:
|
||||
name: {{ template "kube-prometheus-stack.fullname" . }}-self-signed-issuer
|
||||
commonName: "ca.webhook.kube-prometheus-stack"
|
||||
@@ -43,7 +43,7 @@
|
||||
namespace: {{ template "kube-prometheus-stack.namespace" . }}
|
||||
spec:
|
||||
secretName: {{ template "kube-prometheus-stack.fullname" . }}-admission
|
||||
- duration: 8760h # 1y
|
||||
+ duration: 8760h0m0s # 1y
|
||||
issuerRef:
|
||||
{{- if .Values.prometheusOperator.admissionWebhooks.certManager.issuerRef }}
|
||||
{{- toYaml .Values.prometheusOperator.admissionWebhooks.certManager.issuerRef | nindent 4 }}
|
|
@ -0,0 +1,14 @@
|
|||
--- charts-original/templates/prometheus-operator/serviceaccount.yaml
|
||||
+++ charts/templates/prometheus-operator/serviceaccount.yaml
|
||||
@@ -6,7 +6,11 @@
|
||||
namespace: {{ template "kube-prometheus-stack.namespace" . }}
|
||||
labels:
|
||||
app: {{ template "kube-prometheus-stack.name" . }}-operator
|
||||
+ app.kubernetes.io/name: {{ template "kube-prometheus-stack.name" . }}-prometheus-operator
|
||||
+ app.kubernetes.io/component: prometheus-operator
|
||||
{{ include "kube-prometheus-stack.labels" . | indent 4 }}
|
||||
+{{- if .Values.global.imagePullSecrets }}
|
||||
imagePullSecrets:
|
||||
{{ toYaml .Values.global.imagePullSecrets | indent 2 }}
|
||||
{{- end }}
|
||||
+{{- end }}
|
|
@ -0,0 +1,9 @@
|
|||
--- charts-original/templates/prometheus/_rules.tpl
|
||||
+++ charts/templates/prometheus/_rules.tpl
|
||||
@@ -35,4 +35,4 @@
|
||||
- "prometheus"
|
||||
- "kubernetes-apps"
|
||||
- "etcd"
|
||||
-{{- end }}
|
||||
+{{- end }}
|
||||
\ No newline at end of file
|
|
@ -0,0 +1,12 @@
|
|||
--- charts-original/templates/prometheus/additionalPrometheusRules.yaml
|
||||
+++ charts/templates/prometheus/additionalPrometheusRules.yaml
|
||||
@@ -1,6 +1,9 @@
|
||||
{{- if or .Values.additionalPrometheusRules .Values.additionalPrometheusRulesMap}}
|
||||
apiVersion: v1
|
||||
kind: List
|
||||
+metadata:
|
||||
+ name: {{ include "kube-prometheus-stack.fullname" $ }}-additional-prometheus-rules
|
||||
+ namespace: {{ template "kube-prometheus-stack.namespace" . }}
|
||||
items:
|
||||
{{- if .Values.additionalPrometheusRulesMap }}
|
||||
{{- range $prometheusRuleName, $prometheusRule := .Values.additionalPrometheusRulesMap }}
|
|
@ -0,0 +1,78 @@
|
|||
--- charts-original/templates/prometheus/ingress.yaml
|
||||
+++ charts/templates/prometheus/ingress.yaml
|
||||
@@ -1,14 +1,12 @@
|
||||
-{{- if and .Values.prometheus.enabled .Values.prometheus.ingress.enabled }}
|
||||
-{{- $pathType := .Values.prometheus.ingress.pathType | default "" }}
|
||||
-{{- $serviceName := printf "%s-%s" (include "kube-prometheus-stack.fullname" .) "prometheus" }}
|
||||
-{{- $servicePort := .Values.prometheus.service.port -}}
|
||||
-{{- $routePrefix := list .Values.prometheus.prometheusSpec.routePrefix }}
|
||||
-{{- $paths := .Values.prometheus.ingress.paths | default $routePrefix -}}
|
||||
-{{- if .Capabilities.APIVersions.Has "networking.k8s.io/v1beta1" }}
|
||||
-apiVersion: networking.k8s.io/v1beta1
|
||||
-{{ else }}
|
||||
-apiVersion: extensions/v1beta1
|
||||
-{{ end -}}
|
||||
+{{- if and .Values.prometheus.enabled .Values.prometheus.ingress.enabled -}}
|
||||
+ {{- $pathType := .Values.prometheus.ingress.pathType | default "" -}}
|
||||
+ {{- $serviceName := printf "%s-%s" (include "kube-prometheus-stack.fullname" .) "prometheus" -}}
|
||||
+ {{- $servicePort := .Values.prometheus.service.port -}}
|
||||
+ {{- $routePrefix := list .Values.prometheus.prometheusSpec.routePrefix -}}
|
||||
+ {{- $paths := .Values.prometheus.ingress.paths | default $routePrefix -}}
|
||||
+ {{- $apiIsStable := eq (include "kube-prometheus-stack.ingress.isStable" .) "true" -}}
|
||||
+ {{- $ingressSupportsPathType := eq (include "kube-prometheus-stack.ingress.supportsPathType" .) "true" -}}
|
||||
+apiVersion: {{ include "kube-prometheus-stack.ingress.apiVersion" . }}
|
||||
kind: Ingress
|
||||
metadata:
|
||||
{{- if .Values.prometheus.ingress.annotations }}
|
||||
@@ -24,7 +22,7 @@
|
||||
{{ toYaml .Values.prometheus.ingress.labels | indent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
- {{- if or (.Capabilities.APIVersions.Has "networking.k8s.io/v1") (.Capabilities.APIVersions.Has "networking.k8s.io/v1beta1") }}
|
||||
+ {{- if $apiIsStable }}
|
||||
{{- if .Values.prometheus.ingress.ingressClassName }}
|
||||
ingressClassName: {{ .Values.prometheus.ingress.ingressClassName }}
|
||||
{{- end }}
|
||||
@@ -37,25 +35,39 @@
|
||||
paths:
|
||||
{{- range $p := $paths }}
|
||||
- path: {{ tpl $p $ }}
|
||||
- {{- if $pathType }}
|
||||
+ {{- if and $pathType $ingressSupportsPathType }}
|
||||
pathType: {{ $pathType }}
|
||||
{{- end }}
|
||||
backend:
|
||||
+ {{- if $apiIsStable }}
|
||||
+ service:
|
||||
+ name: {{ $serviceName }}
|
||||
+ port:
|
||||
+ number: {{ $servicePort }}
|
||||
+ {{- else }}
|
||||
serviceName: {{ $serviceName }}
|
||||
servicePort: {{ $servicePort }}
|
||||
- {{- end -}}
|
||||
+ {{- end }}
|
||||
+ {{- end -}}
|
||||
{{- end -}}
|
||||
{{- else }}
|
||||
- http:
|
||||
paths:
|
||||
{{- range $p := $paths }}
|
||||
- path: {{ tpl $p $ }}
|
||||
- {{- if $pathType }}
|
||||
+ {{- if and $pathType $ingressSupportsPathType }}
|
||||
pathType: {{ $pathType }}
|
||||
{{- end }}
|
||||
backend:
|
||||
+ {{- if $apiIsStable }}
|
||||
+ service:
|
||||
+ name: {{ $serviceName }}
|
||||
+ port:
|
||||
+ number: {{ $servicePort }}
|
||||
+ {{- else }}
|
||||
serviceName: {{ $serviceName }}
|
||||
servicePort: {{ $servicePort }}
|
||||
+ {{- end }}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- if .Values.prometheus.ingress.tls }}
|
|
@ -0,0 +1,69 @@
|
|||
--- charts-original/templates/prometheus/ingressThanosSidecar.yaml
|
||||
+++ charts/templates/prometheus/ingressThanosSidecar.yaml
|
||||
@@ -4,11 +4,9 @@
|
||||
{{- $thanosPort := .Values.prometheus.thanosIngress.servicePort -}}
|
||||
{{- $routePrefix := list .Values.prometheus.prometheusSpec.routePrefix }}
|
||||
{{- $paths := .Values.prometheus.thanosIngress.paths | default $routePrefix -}}
|
||||
-{{- if .Capabilities.APIVersions.Has "networking.k8s.io/v1beta1" }}
|
||||
-apiVersion: networking.k8s.io/v1beta1
|
||||
-{{ else }}
|
||||
-apiVersion: extensions/v1beta1
|
||||
-{{ end -}}
|
||||
+{{- $apiIsStable := eq (include "kube-prometheus-stack.ingress.isStable" .) "true" -}}
|
||||
+{{- $ingressSupportsPathType := eq (include "kube-prometheus-stack.ingress.supportsPathType" .) "true" -}}
|
||||
+apiVersion: {{ include "kube-prometheus-stack.ingress.apiVersion" . }}
|
||||
kind: Ingress
|
||||
metadata:
|
||||
{{- if .Values.prometheus.thanosIngress.annotations }}
|
||||
@@ -23,7 +21,7 @@
|
||||
{{ toYaml .Values.prometheus.thanosIngress.labels | indent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
- {{- if or (.Capabilities.APIVersions.Has "networking.k8s.io/v1") (.Capabilities.APIVersions.Has "networking.k8s.io/v1beta1") }}
|
||||
+ {{- if $apiIsStable }}
|
||||
{{- if .Values.prometheus.thanosIngress.ingressClassName }}
|
||||
ingressClassName: {{ .Values.prometheus.thanosIngress.ingressClassName }}
|
||||
{{- end }}
|
||||
@@ -36,25 +34,39 @@
|
||||
paths:
|
||||
{{- range $p := $paths }}
|
||||
- path: {{ tpl $p $ }}
|
||||
- {{- if $pathType }}
|
||||
+ {{- if and $pathType $ingressSupportsPathType }}
|
||||
pathType: {{ $pathType }}
|
||||
{{- end }}
|
||||
backend:
|
||||
+ {{- if $apiIsStable }}
|
||||
+ service:
|
||||
+ name: {{ $serviceName }}
|
||||
+ port:
|
||||
+ number: {{ $thanosPort }}
|
||||
+ {{- else }}
|
||||
serviceName: {{ $serviceName }}
|
||||
servicePort: {{ $thanosPort }}
|
||||
- {{- end -}}
|
||||
+ {{- end }}
|
||||
+ {{- end -}}
|
||||
{{- end -}}
|
||||
{{- else }}
|
||||
- http:
|
||||
paths:
|
||||
{{- range $p := $paths }}
|
||||
- path: {{ tpl $p $ }}
|
||||
- {{- if $pathType }}
|
||||
+ {{- if and $pathType $ingressSupportsPathType }}
|
||||
pathType: {{ $pathType }}
|
||||
{{- end }}
|
||||
backend:
|
||||
+ {{- if $apiIsStable }}
|
||||
+ service:
|
||||
+ name: {{ $serviceName }}
|
||||
+ port:
|
||||
+ number: {{ $thanosPort }}
|
||||
+ {{- else }}
|
||||
serviceName: {{ $serviceName }}
|
||||
servicePort: {{ $thanosPort }}
|
||||
+ {{- end }}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- if .Values.prometheus.thanosIngress.tls }}
|
|
@ -0,0 +1,61 @@
|
|||
--- charts-original/templates/prometheus/ingressperreplica.yaml
|
||||
+++ charts/templates/prometheus/ingressperreplica.yaml
|
||||
@@ -3,6 +3,8 @@
|
||||
{{- $count := .Values.prometheus.prometheusSpec.replicas | int -}}
|
||||
{{- $servicePort := .Values.prometheus.servicePerReplica.port -}}
|
||||
{{- $ingressValues := .Values.prometheus.ingressPerReplica -}}
|
||||
+{{- $apiIsStable := eq (include "kube-prometheus-stack.ingress.isStable" .) "true" -}}
|
||||
+{{- $ingressSupportsPathType := eq (include "kube-prometheus-stack.ingress.supportsPathType" .) "true" -}}
|
||||
apiVersion: v1
|
||||
kind: List
|
||||
metadata:
|
||||
@@ -11,17 +13,13 @@
|
||||
items:
|
||||
{{ range $i, $e := until $count }}
|
||||
- kind: Ingress
|
||||
- {{- if $.Capabilities.APIVersions.Has "networking.k8s.io/v1beta1" }}
|
||||
- apiVersion: networking.k8s.io/v1beta1
|
||||
- {{ else }}
|
||||
- apiVersion: extensions/v1beta1
|
||||
- {{ end -}}
|
||||
+ apiVersion: {{ include "kube-prometheus-stack.ingress.apiVersion" $ }}
|
||||
metadata:
|
||||
name: {{ include "kube-prometheus-stack.fullname" $ }}-prometheus-{{ $i }}
|
||||
namespace: {{ template "kube-prometheus-stack.namespace" $ }}
|
||||
labels:
|
||||
app: {{ include "kube-prometheus-stack.name" $ }}-prometheus
|
||||
-{{ include "kube-prometheus-stack.labels" $ | indent 8 }}
|
||||
+ {{ include "kube-prometheus-stack.labels" $ | indent 8 }}
|
||||
{{- if $ingressValues.labels }}
|
||||
{{ toYaml $ingressValues.labels | indent 8 }}
|
||||
{{- end }}
|
||||
@@ -30,7 +28,7 @@
|
||||
{{ toYaml $ingressValues.annotations | indent 8 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
- {{- if or ($.Capabilities.APIVersions.Has "networking.k8s.io/v1") ($.Capabilities.APIVersions.Has "networking.k8s.io/v1beta1") }}
|
||||
+ {{- if $apiIsStable }}
|
||||
{{- if $ingressValues.ingressClassName }}
|
||||
ingressClassName: {{ $ingressValues.ingressClassName }}
|
||||
{{- end }}
|
||||
@@ -41,12 +39,19 @@
|
||||
paths:
|
||||
{{- range $p := $ingressValues.paths }}
|
||||
- path: {{ tpl $p $ }}
|
||||
- {{- if $pathType }}
|
||||
+ {{- if and $pathType $ingressSupportsPathType }}
|
||||
pathType: {{ $pathType }}
|
||||
{{- end }}
|
||||
backend:
|
||||
+ {{- if $apiIsStable }}
|
||||
+ service:
|
||||
+ name: {{ include "kube-prometheus-stack.fullname" $ }}-prometheus-{{ $i }}
|
||||
+ port:
|
||||
+ number: {{ $servicePort }}
|
||||
+ {{- else }}
|
||||
serviceName: {{ include "kube-prometheus-stack.fullname" $ }}-prometheus-{{ $i }}
|
||||
servicePort: {{ $servicePort }}
|
||||
+ {{- end }}
|
||||
{{- end -}}
|
||||
{{- if or $ingressValues.tlsSecretName $ingressValues.tlsSecretPerReplica.enabled }}
|
||||
tls:
|
|
@ -0,0 +1,10 @@
|
|||
--- charts-original/templates/prometheus/podDisruptionBudget.yaml
|
||||
+++ charts/templates/prometheus/podDisruptionBudget.yaml
|
||||
@@ -16,6 +16,6 @@
|
||||
{{- end }}
|
||||
selector:
|
||||
matchLabels:
|
||||
- app: prometheus
|
||||
+ app.kubernetes.io/name: prometheus
|
||||
prometheus: {{ template "kube-prometheus-stack.fullname" . }}-prometheus
|
||||
{{- end }}
|
|
@ -27,7 +27,62 @@
|
|||
{{ toYaml .Values.prometheus.prometheusSpec.nodeSelector | indent 4 }}
|
||||
{{- end }}
|
||||
paused: {{ .Values.prometheus.prometheusSpec.paused }}
|
||||
@@ -216,8 +221,8 @@
|
||||
@@ -70,6 +75,12 @@
|
||||
logFormat: {{ .Values.prometheus.prometheusSpec.logFormat }}
|
||||
listenLocal: {{ .Values.prometheus.prometheusSpec.listenLocal }}
|
||||
enableAdminAPI: {{ .Values.prometheus.prometheusSpec.enableAdminAPI }}
|
||||
+{{- if .Values.prometheus.prometheusSpec.enableFeatures }}
|
||||
+ enableFeatures:
|
||||
+{{- range $enableFeatures := .Values.prometheus.prometheusSpec.enableFeatures }}
|
||||
+ - {{ tpl $enableFeatures $ }}
|
||||
+{{- end }}
|
||||
+{{- end }}
|
||||
{{- if .Values.prometheus.prometheusSpec.scrapeInterval }}
|
||||
scrapeInterval: {{ .Values.prometheus.prometheusSpec.scrapeInterval }}
|
||||
{{- end }}
|
||||
@@ -150,13 +161,23 @@
|
||||
{{ else }}
|
||||
probeNamespaceSelector: {}
|
||||
{{- end }}
|
||||
-{{- if .Values.prometheus.prometheusSpec.remoteRead }}
|
||||
+{{- if (or .Values.prometheus.prometheusSpec.remoteRead .Values.prometheus.prometheusSpec.additionalRemoteRead) }}
|
||||
remoteRead:
|
||||
-{{ toYaml .Values.prometheus.prometheusSpec.remoteRead | indent 4 }}
|
||||
+{{- if .Values.prometheus.prometheusSpec.remoteRead }}
|
||||
+{{ tpl (toYaml .Values.prometheus.prometheusSpec.remoteRead | indent 4) . }}
|
||||
{{- end }}
|
||||
-{{- if .Values.prometheus.prometheusSpec.remoteWrite }}
|
||||
+{{- if .Values.prometheus.prometheusSpec.additionalRemoteRead }}
|
||||
+{{ toYaml .Values.prometheus.prometheusSpec.additionalRemoteRead | indent 4 }}
|
||||
+{{- end }}
|
||||
+{{- end }}
|
||||
+{{- if (or .Values.prometheus.prometheusSpec.remoteWrite .Values.prometheus.prometheusSpec.additionalRemoteWrite) }}
|
||||
remoteWrite:
|
||||
-{{ toYaml .Values.prometheus.prometheusSpec.remoteWrite | indent 4 }}
|
||||
+{{- if .Values.prometheus.prometheusSpec.remoteWrite }}
|
||||
+{{ tpl (toYaml .Values.prometheus.prometheusSpec.remoteWrite | indent 4) . }}
|
||||
+{{- end }}
|
||||
+{{- if .Values.prometheus.prometheusSpec.additionalRemoteWrite }}
|
||||
+{{ toYaml .Values.prometheus.prometheusSpec.additionalRemoteWrite | indent 4 }}
|
||||
+{{- end }}
|
||||
{{- end }}
|
||||
{{- if .Values.prometheus.prometheusSpec.securityContext }}
|
||||
securityContext:
|
||||
@@ -202,7 +223,7 @@
|
||||
- topologyKey: {{ .Values.prometheus.prometheusSpec.podAntiAffinityTopologyKey }}
|
||||
labelSelector:
|
||||
matchExpressions:
|
||||
- - {key: app, operator: In, values: [prometheus]}
|
||||
+ - {key: app.kubernetes.io/name, operator: In, values: [prometheus]}
|
||||
- {key: prometheus, operator: In, values: [{{ template "kube-prometheus-stack.fullname" . }}-prometheus]}
|
||||
{{- else if eq .Values.prometheus.prometheusSpec.podAntiAffinity "soft" }}
|
||||
podAntiAffinity:
|
||||
@@ -212,12 +233,12 @@
|
||||
topologyKey: {{ .Values.prometheus.prometheusSpec.podAntiAffinityTopologyKey }}
|
||||
labelSelector:
|
||||
matchExpressions:
|
||||
- - {key: app, operator: In, values: [prometheus]}
|
||||
+ - {key: app.kubernetes.io/name, operator: In, values: [prometheus]}
|
||||
- {key: prometheus, operator: In, values: [{{ template "kube-prometheus-stack.fullname" . }}-prometheus]}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
@ -37,7 +92,7 @@
|
|||
{{ toYaml .Values.prometheus.prometheusSpec.tolerations | indent 4 }}
|
||||
{{- end }}
|
||||
{{- if .Values.prometheus.prometheusSpec.topologySpreadConstraints }}
|
||||
@@ -250,7 +255,7 @@
|
||||
@@ -250,7 +271,7 @@
|
||||
{{- end }}
|
||||
{{- if .Values.prometheus.prometheusSpec.containers }}
|
||||
containers:
|
||||
|
@ -46,7 +101,7 @@
|
|||
{{- end }}
|
||||
{{- if .Values.prometheus.prometheusSpec.initContainers }}
|
||||
initContainers:
|
||||
@@ -266,6 +271,7 @@
|
||||
@@ -266,6 +287,7 @@
|
||||
{{- if .Values.prometheus.prometheusSpec.disableCompaction }}
|
||||
disableCompaction: {{ .Values.prometheus.prometheusSpec.disableCompaction }}
|
||||
{{- end }}
|
||||
|
@ -54,7 +109,7 @@
|
|||
portName: {{ .Values.prometheus.prometheusSpec.portName }}
|
||||
{{- end }}
|
||||
{{- if .Values.prometheus.prometheusSpec.volumes }}
|
||||
@@ -310,3 +316,4 @@
|
||||
@@ -310,3 +332,4 @@
|
||||
{{- if .Values.prometheus.prometheusSpec.allowOverlappingBlocks }}
|
||||
allowOverlappingBlocks: {{ .Values.prometheus.prometheusSpec.allowOverlappingBlocks }}
|
||||
{{- end }}
|
||||
|
|
|
@ -1,6 +1,10 @@
|
|||
--- charts-original/templates/prometheus/rules-1.14/etcd.yaml
|
||||
+++ charts/templates/prometheus/rules-1.14/etcd.yaml
|
||||
@@ -4,7 +4,8 @@
|
||||
@@ -1,10 +1,11 @@
|
||||
{{- /*
|
||||
-Generated from 'etcd' group from https://raw.githubusercontent.com/etcd-io/website/master/content/docs/v3.4.0/op-guide/etcd3_alert.rules.yml
|
||||
+Generated from 'etcd' group from https://raw.githubusercontent.com/etcd-io/website/master/content/en/docs/v3.4/op-guide/etcd3_alert.rules.yml
|
||||
Do not change in-place! In order to change this file first read following link:
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
--- charts-original/templates/prometheus/rules-1.14/k8s.rules.yaml
|
||||
+++ charts/templates/prometheus/rules-1.14/k8s.rules.yaml
|
||||
@@ -26,31 +26,31 @@
|
||||
@@ -26,57 +26,57 @@
|
||||
rules:
|
||||
- expr: |-
|
||||
sum by (cluster, namespace, pod, container) (
|
||||
- rate(container_cpu_usage_seconds_total{job="kubelet", metrics_path="/metrics/cadvisor", image!="", container!="POD"}[5m])
|
||||
+ rate(container_cpu_usage_seconds_total{job="{{ include "exporter.kubelet.jobName" . }}", metrics_path="/metrics/cadvisor", image!="", container!="POD"}[5m])
|
||||
+ rate(container_cpu_usage_seconds_total{job="{{ include "exporter.kubelet.jobName" . }}", metrics_path="/metrics/cadvisor", image!=""}[5m])
|
||||
) * on (cluster, namespace, pod) group_left(node) topk by (cluster, namespace, pod) (
|
||||
1, max by(cluster, namespace, pod, node) (kube_pod_info{node!=""})
|
||||
)
|
||||
|
@ -37,3 +37,42 @@
|
|||
* on (namespace, pod) group_left(node) topk by(namespace, pod) (1,
|
||||
max by(namespace, pod, node) (kube_pod_info{node!=""})
|
||||
)
|
||||
record: node_namespace_pod_container:container_memory_swap
|
||||
- expr: |-
|
||||
- sum by (namespace) (
|
||||
- sum by (namespace, pod) (
|
||||
- max by (namespace, pod, container) (
|
||||
- kube_pod_container_resource_requests_memory_bytes{job="kube-state-metrics"}
|
||||
- ) * on(namespace, pod) group_left() max by (namespace, pod) (
|
||||
- kube_pod_status_phase{phase=~"Pending|Running"} == 1
|
||||
+ sum by (namespace, cluster) (
|
||||
+ sum by (namespace, pod, cluster) (
|
||||
+ max by (namespace, pod, container, cluster) (
|
||||
+ kube_pod_container_resource_requests{resource="memory",job="kube-state-metrics"}
|
||||
+ ) * on(namespace, pod, cluster) group_left() max by (namespace, pod) (
|
||||
+ kube_pod_status_phase{phase=~"Pending|Running"} == 1
|
||||
)
|
||||
)
|
||||
)
|
||||
- record: namespace:kube_pod_container_resource_requests_memory_bytes:sum
|
||||
+ record: namespace_memory:kube_pod_container_resource_requests:sum
|
||||
- expr: |-
|
||||
- sum by (namespace) (
|
||||
- sum by (namespace, pod) (
|
||||
- max by (namespace, pod, container) (
|
||||
- kube_pod_container_resource_requests_cpu_cores{job="kube-state-metrics"}
|
||||
- ) * on(namespace, pod) group_left() max by (namespace, pod) (
|
||||
+ sum by (namespace, cluster) (
|
||||
+ sum by (namespace, pod, cluster) (
|
||||
+ max by (namespace, pod, container, cluster) (
|
||||
+ kube_pod_container_resource_requests{resource="cpu",job="kube-state-metrics"}
|
||||
+ ) * on(namespace, pod, cluster) group_left() max by (namespace, pod) (
|
||||
kube_pod_status_phase{phase=~"Pending|Running"} == 1
|
||||
)
|
||||
)
|
||||
)
|
||||
- record: namespace:kube_pod_container_resource_requests_cpu_cores:sum
|
||||
+ record: namespace_cpu:kube_pod_container_resource_requests:sum
|
||||
- expr: |-
|
||||
max by (cluster, namespace, workload, pod) (
|
||||
label_replace(
|
||||
|
|
|
@ -0,0 +1,29 @@
|
|||
--- charts-original/templates/prometheus/rules-1.14/kubernetes-apps.yaml
|
||||
+++ charts/templates/prometheus/rules-1.14/kubernetes-apps.yaml
|
||||
@@ -82,7 +82,7 @@
|
||||
!=
|
||||
kube_deployment_status_replicas_available{job="kube-state-metrics", namespace=~"{{ $targetNamespace }}"}
|
||||
) and (
|
||||
- changes(kube_deployment_status_replicas_updated{job="kube-state-metrics", namespace=~"{{ $targetNamespace }}"}[5m])
|
||||
+ changes(kube_deployment_status_replicas_updated{job="kube-state-metrics", namespace=~"{{ $targetNamespace }}"}[10m])
|
||||
==
|
||||
0
|
||||
)
|
||||
@@ -103,7 +103,7 @@
|
||||
!=
|
||||
kube_statefulset_status_replicas{job="kube-state-metrics", namespace=~"{{ $targetNamespace }}"}
|
||||
) and (
|
||||
- changes(kube_statefulset_status_replicas_updated{job="kube-state-metrics", namespace=~"{{ $targetNamespace }}"}[5m])
|
||||
+ changes(kube_statefulset_status_replicas_updated{job="kube-state-metrics", namespace=~"{{ $targetNamespace }}"}[10m])
|
||||
==
|
||||
0
|
||||
)
|
||||
@@ -273,7 +273,7 @@
|
||||
<
|
||||
kube_hpa_spec_max_replicas{job="kube-state-metrics", namespace=~"{{ $targetNamespace }}"})
|
||||
and
|
||||
- changes(kube_hpa_status_current_replicas[15m]) == 0
|
||||
+ changes(kube_hpa_status_current_replicas{job="kube-state-metrics", namespace=~"{{ $targetNamespace }}"}[15m]) == 0
|
||||
for: 15m
|
||||
labels:
|
||||
severity: warning
|
|
@ -0,0 +1,53 @@
|
|||
--- charts-original/templates/prometheus/rules-1.14/kubernetes-resources.yaml
|
||||
+++ charts/templates/prometheus/rules-1.14/kubernetes-resources.yaml
|
||||
@@ -30,11 +30,11 @@
|
||||
runbook_url: {{ .Values.defaultRules.runbookUrl }}alert-name-kubecpuovercommit
|
||||
summary: Cluster has overcommitted CPU resource requests.
|
||||
expr: |-
|
||||
- sum(namespace:kube_pod_container_resource_requests_cpu_cores:sum{})
|
||||
+ sum(namespace_cpu:kube_pod_container_resource_requests:sum{})
|
||||
/
|
||||
- sum(kube_node_status_allocatable_cpu_cores)
|
||||
+ sum(kube_node_status_allocatable{resource="cpu"})
|
||||
>
|
||||
- (count(kube_node_status_allocatable_cpu_cores)-1) / count(kube_node_status_allocatable_cpu_cores)
|
||||
+ ((count(kube_node_status_allocatable{resource="cpu"}) > 1) - 1) / count(kube_node_status_allocatable{resource="cpu"})
|
||||
for: 5m
|
||||
labels:
|
||||
severity: warning
|
||||
@@ -47,13 +47,13 @@
|
||||
runbook_url: {{ .Values.defaultRules.runbookUrl }}alert-name-kubememoryovercommit
|
||||
summary: Cluster has overcommitted memory resource requests.
|
||||
expr: |-
|
||||
- sum(namespace:kube_pod_container_resource_requests_memory_bytes:sum{})
|
||||
+ sum(namespace_memory:kube_pod_container_resource_requests:sum{})
|
||||
/
|
||||
- sum(kube_node_status_allocatable_memory_bytes)
|
||||
+ sum(kube_node_status_allocatable{resource="memory"})
|
||||
>
|
||||
- (count(kube_node_status_allocatable_memory_bytes)-1)
|
||||
+ ((count(kube_node_status_allocatable{resource="memory"}) > 1) - 1)
|
||||
/
|
||||
- count(kube_node_status_allocatable_memory_bytes)
|
||||
+ count(kube_node_status_allocatable{resource="memory"})
|
||||
for: 5m
|
||||
labels:
|
||||
severity: warning
|
||||
@@ -68,7 +68,7 @@
|
||||
expr: |-
|
||||
sum(kube_resourcequota{job="kube-state-metrics", type="hard", resource="cpu"})
|
||||
/
|
||||
- sum(kube_node_status_allocatable_cpu_cores)
|
||||
+ sum(kube_node_status_allocatable{resource="cpu"})
|
||||
> 1.5
|
||||
for: 5m
|
||||
labels:
|
||||
@@ -84,7 +84,7 @@
|
||||
expr: |-
|
||||
sum(kube_resourcequota{job="kube-state-metrics", type="hard", resource="memory"})
|
||||
/
|
||||
- sum(kube_node_status_allocatable_memory_bytes{job="kube-state-metrics"})
|
||||
+ sum(kube_node_status_allocatable{resource="memory",job="kube-state-metrics"})
|
||||
> 1.5
|
||||
for: 5m
|
||||
labels:
|
|
@ -0,0 +1,11 @@
|
|||
--- charts-original/templates/prometheus/rules-1.14/kubernetes-system-apiserver.yaml
|
||||
+++ charts/templates/prometheus/rules-1.14/kubernetes-system-apiserver.yaml
|
||||
@@ -51,7 +51,7 @@
|
||||
description: An aggregated API {{`{{`}} $labels.name {{`}}`}}/{{`{{`}} $labels.namespace {{`}}`}} has reported errors. It has appeared unavailable {{`{{`}} $value | humanize {{`}}`}} times averaged over the past 10m.
|
||||
runbook_url: {{ .Values.defaultRules.runbookUrl }}alert-name-aggregatedapierrors
|
||||
summary: An aggregated API has reported errors.
|
||||
- expr: sum by(name, namespace)(increase(aggregator_unavailable_apiservice_count[10m])) > 4
|
||||
+ expr: sum by(name, namespace)(increase(aggregator_unavailable_apiservice_total[10m])) > 4
|
||||
labels:
|
||||
severity: warning
|
||||
{{- if .Values.defaultRules.additionalRuleLabels }}
|
|
@ -1,5 +1,14 @@
|
|||
--- charts-original/templates/prometheus/rules-1.14/kubernetes-system-kubelet.yaml
|
||||
+++ charts/templates/prometheus/rules-1.14/kubernetes-system-kubelet.yaml
|
||||
@@ -59,7 +59,7 @@
|
||||
)
|
||||
/
|
||||
max by(node) (
|
||||
- kube_node_status_capacity_pods{job="kube-state-metrics"} != 1
|
||||
+ kube_node_status_capacity{job="kube-state-metrics",resource="pods"} != 1
|
||||
) > 0.95
|
||||
for: 15m
|
||||
labels:
|
||||
@@ -96,7 +96,7 @@
|
||||
description: Kubelet Pod startup 99th percentile latency is {{`{{`}} $value {{`}}`}} seconds on node {{`{{`}} $labels.node {{`}}`}}.
|
||||
runbook_url: {{ .Values.defaultRules.runbookUrl }}alert-name-kubeletpodstartuplatencyhigh
|
||||
|
|
|
@ -0,0 +1,11 @@
|
|||
--- charts-original/templates/prometheus/rules-1.14/kubernetes-system.yaml
|
||||
+++ charts/templates/prometheus/rules-1.14/kubernetes-system.yaml
|
||||
@@ -29,7 +29,7 @@
|
||||
description: There are {{`{{`}} $value {{`}}`}} different semantic versions of Kubernetes components running.
|
||||
runbook_url: {{ .Values.defaultRules.runbookUrl }}alert-name-kubeversionmismatch
|
||||
summary: Different semantic versions of Kubernetes components running.
|
||||
- expr: count(count by (gitVersion) (label_replace(kubernetes_build_info{job!~"kube-dns|coredns"},"gitVersion","$1","gitVersion","(v[0-9]*.[0-9]*).*"))) > 1
|
||||
+ expr: count(count by (git_version) (label_replace(kubernetes_build_info{job!~"kube-dns|coredns"},"git_version","$1","git_version","(v[0-9]*.[0-9]*).*"))) > 1
|
||||
for: 15m
|
||||
labels:
|
||||
severity: warning
|
|
@ -0,0 +1,11 @@
|
|||
--- charts-original/templates/prometheus/rules-1.14/node.rules.yaml
|
||||
+++ charts/templates/prometheus/rules-1.14/node.rules.yaml
|
||||
@@ -34,7 +34,7 @@
|
||||
count by (cluster, node) (sum by (node, cpu) (
|
||||
node_cpu_seconds_total{job="node-exporter"}
|
||||
* on (namespace, pod) group_left(node)
|
||||
- node_namespace_pod:kube_pod_info:
|
||||
+ topk by(namespace, pod) (1, node_namespace_pod:kube_pod_info:)
|
||||
))
|
||||
record: node:node_num_cpu:sum
|
||||
- expr: |-
|
|
@ -1,6 +1,10 @@
|
|||
--- charts-original/templates/prometheus/rules/etcd.yaml
|
||||
+++ charts/templates/prometheus/rules/etcd.yaml
|
||||
@@ -4,7 +4,8 @@
|
||||
@@ -1,10 +1,11 @@
|
||||
{{- /*
|
||||
-Generated from 'etcd' group from https://raw.githubusercontent.com/etcd-io/website/master/content/docs/v3.4.0/op-guide/etcd3_alert.rules.yml
|
||||
+Generated from 'etcd' group from https://raw.githubusercontent.com/etcd-io/website/master/content/en/docs/v3.4/op-guide/etcd3_alert.rules.yml
|
||||
Do not change in-place! In order to change this file first read following link:
|
||||
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack/hack
|
||||
*/ -}}
|
||||
{{- $kubeTargetVersion := default .Capabilities.KubeVersion.GitVersion .Values.kubeTargetVersionOverride }}
|
||||
|
|
|
@ -0,0 +1,11 @@
|
|||
--- charts-original/templates/prometheus/service.yaml
|
||||
+++ charts/templates/prometheus/service.yaml
|
||||
@@ -51,7 +51,7 @@
|
||||
{{ toYaml .Values.prometheus.service.additionalPorts | indent 2 }}
|
||||
{{- end }}
|
||||
selector:
|
||||
- app: prometheus
|
||||
+ app.kubernetes.io/name: prometheus
|
||||
prometheus: {{ template "kube-prometheus-stack.fullname" . }}-prometheus
|
||||
{{- if .Values.prometheus.service.sessionAffinity }}
|
||||
sessionAffinity: {{ .Values.prometheus.service.sessionAffinity }}
|
|
@ -0,0 +1,10 @@
|
|||
--- charts-original/templates/prometheus/serviceThanosSidecar.yaml
|
||||
+++ charts/templates/prometheus/serviceThanosSidecar.yaml
|
||||
@@ -25,6 +25,6 @@
|
||||
nodePort: {{ .Values.prometheus.thanosService.nodePort }}
|
||||
{{- end }}
|
||||
selector:
|
||||
- app: prometheus
|
||||
+ app.kubernetes.io/name: prometheus
|
||||
prometheus: {{ template "kube-prometheus-stack.fullname" . }}-prometheus
|
||||
{{- end }}
|
|
@ -0,0 +1,18 @@
|
|||
--- charts-original/templates/prometheus/serviceaccount.yaml
|
||||
+++ charts/templates/prometheus/serviceaccount.yaml
|
||||
@@ -6,11 +6,15 @@
|
||||
namespace: {{ template "kube-prometheus-stack.namespace" . }}
|
||||
labels:
|
||||
app: {{ template "kube-prometheus-stack.name" . }}-prometheus
|
||||
+ app.kubernetes.io/name: {{ template "kube-prometheus-stack.name" . }}-prometheus
|
||||
+ app.kubernetes.io/component: prometheus
|
||||
{{ include "kube-prometheus-stack.labels" . | indent 4 }}
|
||||
{{- if .Values.prometheus.serviceAccount.annotations }}
|
||||
annotations:
|
||||
{{ toYaml .Values.prometheus.serviceAccount.annotations | indent 4 }}
|
||||
{{- end }}
|
||||
+{{- if .Values.global.imagePullSecrets }}
|
||||
imagePullSecrets:
|
||||
{{ toYaml .Values.global.imagePullSecrets | indent 2 }}
|
||||
{{- end }}
|
||||
+{{- end }}
|
|
@ -0,0 +1,11 @@
|
|||
--- charts-original/templates/prometheus/serviceperreplica.yaml
|
||||
+++ charts/templates/prometheus/serviceperreplica.yaml
|
||||
@@ -38,7 +38,7 @@
|
||||
port: {{ $serviceValues.port }}
|
||||
targetPort: {{ $serviceValues.targetPort }}
|
||||
selector:
|
||||
- app: prometheus
|
||||
+ app.kubernetes.io/name: prometheus
|
||||
prometheus: {{ include "kube-prometheus-stack.fullname" $ }}-prometheus
|
||||
statefulset.kubernetes.io/pod-name: prometheus-{{ include "kube-prometheus-stack.fullname" $ }}-prometheus-{{ $i }}
|
||||
type: "{{ $serviceValues.type }}"
|
|
@ -1,6 +1,6 @@
|
|||
--- charts-original/values.yaml
|
||||
+++ charts/values.yaml
|
||||
@@ -2,13 +2,423 @@
|
||||
@@ -2,18 +2,432 @@
|
||||
# This is a YAML-formatted file.
|
||||
# Declare variables to be passed into your templates.
|
||||
|
||||
|
@ -426,7 +426,16 @@
|
|||
|
||||
## Provide a k8s version to auto dashboard import script example: kubeTargetVersionOverride: 1.16.6
|
||||
##
|
||||
@@ -89,8 +499,32 @@
|
||||
kubeTargetVersionOverride: ""
|
||||
|
||||
+## Allow kubeVersion to be overridden while creating the ingress
|
||||
+##
|
||||
+kubeVersionOverride: ""
|
||||
+
|
||||
## Provide a name to substitute for the full names of resources
|
||||
##
|
||||
fullnameOverride: ""
|
||||
@@ -89,8 +503,32 @@
|
||||
|
||||
##
|
||||
global:
|
||||
|
@ -459,7 +468,18 @@
|
|||
pspEnabled: true
|
||||
pspAnnotations: {}
|
||||
## Specify pod annotations
|
||||
@@ -143,6 +577,22 @@
|
||||
@@ -117,6 +555,10 @@
|
||||
##
|
||||
enabled: true
|
||||
|
||||
+ ## Annotations for Alertmanager
|
||||
+ ##
|
||||
+ annotations: {}
|
||||
+
|
||||
## Api that prometheus will use to communicate with alertmanager. Possible values are v1, v2
|
||||
##
|
||||
apiVersion: v2
|
||||
@@ -143,6 +585,22 @@
|
||||
## ref: https://prometheus.io/docs/alerting/configuration/#configuration-file
|
||||
## https://prometheus.io/webtools/alerting/routing-tree-editor/
|
||||
##
|
||||
|
@ -482,7 +502,7 @@
|
|||
config:
|
||||
global:
|
||||
resolve_timeout: 5m
|
||||
@@ -179,25 +629,76 @@
|
||||
@@ -179,25 +637,76 @@
|
||||
## ref: https://prometheus.io/docs/alerting/notifications/
|
||||
## https://prometheus.io/docs/alerting/notification_examples/
|
||||
##
|
||||
|
@ -578,7 +598,7 @@
|
|||
|
||||
ingress:
|
||||
enabled: false
|
||||
@@ -235,6 +736,25 @@
|
||||
@@ -235,6 +744,25 @@
|
||||
## Configuration for Alertmanager secret
|
||||
##
|
||||
secret:
|
||||
|
@ -604,7 +624,18 @@
|
|||
annotations: {}
|
||||
|
||||
## Configuration for creating an Ingress that will map to each Alertmanager replica service
|
||||
@@ -352,7 +872,7 @@
|
||||
@@ -345,6 +873,10 @@
|
||||
interval: ""
|
||||
selfMonitor: true
|
||||
|
||||
+ ## proxyUrl: URL of a proxy that should be used for scraping.
|
||||
+ ##
|
||||
+ proxyUrl: ""
|
||||
+
|
||||
## scheme: HTTP scheme to use for scraping. Can be used with `tlsConfig` for example if using istio mTLS.
|
||||
scheme: ""
|
||||
|
||||
@@ -352,7 +884,7 @@
|
||||
## Of type: https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#tlsconfig
|
||||
tlsConfig: {}
|
||||
|
||||
|
@ -613,16 +644,27 @@
|
|||
|
||||
## metric relabel configs to apply to samples before ingestion.
|
||||
##
|
||||
@@ -383,7 +903,7 @@
|
||||
@@ -375,7 +907,7 @@
|
||||
## ref: https://github.com/prometheus-operator/prometheus-operator/blob/master/Documentation/api.md#alertmanagerspec
|
||||
##
|
||||
alertmanagerSpec:
|
||||
- ## Standard object’s metadata. More info: https://github.com/kubernetes/community/blob/master/contributors/devel/sig-architecture/api-conventions.md#metadata
|
||||
+ ## Standard object's metadata. More info: https://github.com/kubernetes/community/blob/master/contributors/devel/sig-architecture/api-conventions.md#metadata
|
||||
## Metadata Labels and Annotations gets propagated to the Alertmanager pods.
|
||||
##
|
||||
podMetadata: {}
|
||||
@@ -383,8 +915,8 @@
|
||||
## Image of Alertmanager
|
||||
##
|
||||
image:
|
||||
- repository: quay.io/prometheus/alertmanager
|
||||
+ repository: rancher/mirrored-prom-alertmanager
|
||||
tag: v0.21.0
|
||||
- tag: v0.21.0
|
||||
+ repository: rancher/mirrored-prometheus-alertmanager
|
||||
+ tag: v0.22.2
|
||||
sha: ""
|
||||
|
||||
@@ -495,9 +1015,13 @@
|
||||
## If true then the user will be responsible to provide a secret with alertmanager configuration
|
||||
@@ -495,9 +1027,13 @@
|
||||
## Define resources requests and limits for single Pods.
|
||||
## ref: https://kubernetes.io/docs/user-guide/compute-resources/
|
||||
##
|
||||
|
@ -639,7 +681,7 @@
|
|||
|
||||
## Pod anti-affinity can prevent the scheduler from placing Prometheus replicas on the same node.
|
||||
## The default value "soft" means that the scheduler should *prefer* to not schedule two replica pods onto the same node but no guarantee is provided.
|
||||
@@ -601,10 +1125,46 @@
|
||||
@@ -601,10 +1137,54 @@
|
||||
enabled: true
|
||||
namespaceOverride: ""
|
||||
|
||||
|
@ -666,6 +708,14 @@
|
|||
+
|
||||
+ deploymentStrategy:
|
||||
+ type: Recreate
|
||||
+
|
||||
+ ## ForceDeployDatasources Create datasource configmap even if grafana deployment has been disabled
|
||||
+ ##
|
||||
+ forceDeployDatasources: false
|
||||
+
|
||||
+ ## ForceDeployDashboard Create dashboard configmap even if grafana deployment has been disabled
|
||||
+ ##
|
||||
+ forceDeployDashboards: false
|
||||
+
|
||||
## Deploy default dashboards.
|
||||
##
|
||||
|
@ -686,7 +736,7 @@
|
|||
adminPassword: prom-operator
|
||||
|
||||
ingress:
|
||||
@@ -644,6 +1204,7 @@
|
||||
@@ -644,6 +1224,7 @@
|
||||
dashboards:
|
||||
enabled: true
|
||||
label: grafana_dashboard
|
||||
|
@ -694,7 +744,18 @@
|
|||
|
||||
## Annotations for Grafana dashboard configmaps
|
||||
##
|
||||
@@ -692,7 +1253,60 @@
|
||||
@@ -653,6 +1234,10 @@
|
||||
enabled: true
|
||||
defaultDatasourceEnabled: true
|
||||
|
||||
+ ## URL of prometheus datasource
|
||||
+ ##
|
||||
+ # url: http://prometheus-stack-prometheus:9090/
|
||||
+
|
||||
# If not defined, will use prometheus.prometheusSpec.scrapeInterval or its default
|
||||
# defaultDatasourceScrapeInterval: 15s
|
||||
|
||||
@@ -692,7 +1277,60 @@
|
||||
## Passed to grafana subchart and used by servicemonitor below
|
||||
##
|
||||
service:
|
||||
|
@ -756,7 +817,7 @@
|
|||
|
||||
## If true, create a serviceMonitor for grafana
|
||||
##
|
||||
@@ -722,6 +1336,14 @@
|
||||
@@ -722,6 +1360,14 @@
|
||||
# targetLabel: nodename
|
||||
# replacement: $1
|
||||
# action: replace
|
||||
|
@ -771,7 +832,62 @@
|
|||
|
||||
## Component scraping the kube api server
|
||||
##
|
||||
@@ -879,7 +1501,7 @@
|
||||
@@ -730,23 +1376,14 @@
|
||||
tlsConfig:
|
||||
serverName: kubernetes
|
||||
insecureSkipVerify: false
|
||||
-
|
||||
- ## If your API endpoint address is not reachable (as in AKS) you can replace it with the kubernetes service
|
||||
- ##
|
||||
- relabelings: []
|
||||
- # - sourceLabels:
|
||||
- # - __meta_kubernetes_namespace
|
||||
- # - __meta_kubernetes_service_name
|
||||
- # - __meta_kubernetes_endpoint_port_name
|
||||
- # action: keep
|
||||
- # regex: default;kubernetes;https
|
||||
- # - targetLabel: __address__
|
||||
- # replacement: kubernetes.default.svc:443
|
||||
-
|
||||
serviceMonitor:
|
||||
## Scrape interval. If not set, the Prometheus default scrape interval is used.
|
||||
##
|
||||
interval: ""
|
||||
+ ## proxyUrl: URL of a proxy that should be used for scraping.
|
||||
+ ##
|
||||
+ proxyUrl: ""
|
||||
+
|
||||
jobLabel: component
|
||||
selector:
|
||||
matchLabels:
|
||||
@@ -759,6 +1396,15 @@
|
||||
# - action: keep
|
||||
# regex: 'kube_(daemonset|deployment|pod|namespace|node|statefulset).+'
|
||||
# sourceLabels: [__name__]
|
||||
+ relabelings: []
|
||||
+ # - sourceLabels:
|
||||
+ # - __meta_kubernetes_namespace
|
||||
+ # - __meta_kubernetes_service_name
|
||||
+ # - __meta_kubernetes_endpoint_port_name
|
||||
+ # action: keep
|
||||
+ # regex: default;kubernetes;https
|
||||
+ # - targetLabel: __address__
|
||||
+ # replacement: kubernetes.default.svc:443
|
||||
|
||||
## Component scraping the kubelet and kubelet-hosted cAdvisor
|
||||
##
|
||||
@@ -771,6 +1417,10 @@
|
||||
##
|
||||
interval: ""
|
||||
|
||||
+ ## proxyUrl: URL of a proxy that should be used for scraping.
|
||||
+ ##
|
||||
+ proxyUrl: ""
|
||||
+
|
||||
## Enable scraping the kubelet over https. For requirements to enable this see
|
||||
## https://github.com/prometheus-operator/prometheus-operator/issues/926
|
||||
##
|
||||
@@ -879,7 +1529,7 @@
|
||||
## Component scraping the kube controller manager
|
||||
##
|
||||
kubeControllerManager:
|
||||
|
@ -780,7 +896,40 @@
|
|||
|
||||
## If your kube controller manager is not deployed as a pod, specify IPs it can be found on
|
||||
##
|
||||
@@ -1014,7 +1636,7 @@
|
||||
@@ -903,6 +1553,10 @@
|
||||
##
|
||||
interval: ""
|
||||
|
||||
+ ## proxyUrl: URL of a proxy that should be used for scraping.
|
||||
+ ##
|
||||
+ proxyUrl: ""
|
||||
+
|
||||
## Enable scraping kube-controller-manager over https.
|
||||
## Requires proper certs (not self-signed) and delegated authentication/authorization checks
|
||||
##
|
||||
@@ -945,6 +1599,10 @@
|
||||
##
|
||||
interval: ""
|
||||
|
||||
+ ## proxyUrl: URL of a proxy that should be used for scraping.
|
||||
+ ##
|
||||
+ proxyUrl: ""
|
||||
+
|
||||
## metric relabel configs to apply to samples before ingestion.
|
||||
##
|
||||
metricRelabelings: []
|
||||
@@ -980,6 +1638,10 @@
|
||||
##
|
||||
interval: ""
|
||||
|
||||
+ ## proxyUrl: URL of a proxy that should be used for scraping.
|
||||
+ ##
|
||||
+ proxyUrl: ""
|
||||
+
|
||||
## metric relabel configs to apply to samples before ingestion.
|
||||
##
|
||||
metricRelabelings: []
|
||||
@@ -1014,7 +1676,7 @@
|
||||
## Component scraping etcd
|
||||
##
|
||||
kubeEtcd:
|
||||
|
@ -789,7 +938,17 @@
|
|||
|
||||
## If your etcd is not deployed as a pod, specify IPs it can be found on
|
||||
##
|
||||
@@ -1076,7 +1698,7 @@
|
||||
@@ -1048,6 +1710,9 @@
|
||||
## Scrape interval. If not set, the Prometheus default scrape interval is used.
|
||||
##
|
||||
interval: ""
|
||||
+ ## proxyUrl: URL of a proxy that should be used for scraping.
|
||||
+ ##
|
||||
+ proxyUrl: ""
|
||||
scheme: http
|
||||
insecureSkipVerify: false
|
||||
serverName: ""
|
||||
@@ -1076,7 +1741,7 @@
|
||||
## Component scraping kube scheduler
|
||||
##
|
||||
kubeScheduler:
|
||||
|
@ -798,7 +957,17 @@
|
|||
|
||||
## If your kube scheduler is not deployed as a pod, specify IPs it can be found on
|
||||
##
|
||||
@@ -1131,7 +1753,7 @@
|
||||
@@ -1099,6 +1764,9 @@
|
||||
## Scrape interval. If not set, the Prometheus default scrape interval is used.
|
||||
##
|
||||
interval: ""
|
||||
+ ## proxyUrl: URL of a proxy that should be used for scraping.
|
||||
+ ##
|
||||
+ proxyUrl: ""
|
||||
## Enable scraping kube-scheduler over https.
|
||||
## Requires proper certs (not self-signed) and delegated authentication/authorization checks
|
||||
##
|
||||
@@ -1131,7 +1799,7 @@
|
||||
## Component scraping kube proxy
|
||||
##
|
||||
kubeProxy:
|
||||
|
@ -807,7 +976,34 @@
|
|||
|
||||
## If your kube proxy is not deployed as a pod, specify IPs it can be found on
|
||||
##
|
||||
@@ -1210,6 +1832,13 @@
|
||||
@@ -1153,6 +1821,10 @@
|
||||
##
|
||||
interval: ""
|
||||
|
||||
+ ## proxyUrl: URL of a proxy that should be used for scraping.
|
||||
+ ##
|
||||
+ proxyUrl: ""
|
||||
+
|
||||
## Enable scraping kube-proxy over https.
|
||||
## Requires proper certs (not self-signed) and delegated authentication/authorization checks
|
||||
##
|
||||
@@ -1181,9 +1853,15 @@
|
||||
## Scrape interval. If not set, the Prometheus default scrape interval is used.
|
||||
##
|
||||
interval: ""
|
||||
+ ## proxyUrl: URL of a proxy that should be used for scraping.
|
||||
+ ##
|
||||
+ proxyUrl: ""
|
||||
## Override serviceMonitor selector
|
||||
##
|
||||
selectorOverride: {}
|
||||
+ ## Override namespace selector
|
||||
+ ##
|
||||
+ namespaceOverride: ""
|
||||
|
||||
## metric relabel configs to apply to samples before ingestion.
|
||||
##
|
||||
@@ -1210,6 +1888,13 @@
|
||||
create: true
|
||||
podSecurityPolicy:
|
||||
enabled: true
|
||||
|
@ -821,7 +1017,18 @@
|
|||
|
||||
## Deploy node exporter as a daemonset to all nodes
|
||||
##
|
||||
@@ -1259,6 +1888,16 @@
|
||||
@@ -1225,6 +1910,10 @@
|
||||
##
|
||||
interval: ""
|
||||
|
||||
+ ## proxyUrl: URL of a proxy that should be used for scraping.
|
||||
+ ##
|
||||
+ proxyUrl: ""
|
||||
+
|
||||
## How long until a scrape request times out. If not set, the Prometheus default scape timeout is used.
|
||||
##
|
||||
scrapeTimeout: ""
|
||||
@@ -1259,6 +1948,16 @@
|
||||
extraArgs:
|
||||
- --collector.filesystem.ignored-mount-points=^/(dev|proc|sys|var/lib/docker/.+|var/lib/kubelet/.+)($|/)
|
||||
- --collector.filesystem.ignored-fs-types=^(autofs|binfmt_misc|bpf|cgroup2?|configfs|debugfs|devpts|devtmpfs|fusectl|hugetlbfs|iso9660|mqueue|nsfs|overlay|proc|procfs|pstore|rpc_pipefs|securityfs|selinuxfs|squashfs|sysfs|tracefs)$
|
||||
|
@ -838,7 +1045,7 @@
|
|||
|
||||
## Manages Prometheus and Alertmanager components
|
||||
##
|
||||
@@ -1271,8 +1910,8 @@
|
||||
@@ -1271,8 +1970,8 @@
|
||||
enabled: true
|
||||
# Value must match version names from https://golang.org/pkg/crypto/tls/#pkg-constants
|
||||
tlsMinVersion: VersionTLS13
|
||||
|
@ -849,16 +1056,35 @@
|
|||
|
||||
## Admission webhook support for PrometheusRules resources added in Prometheus Operator 0.30 can be enabled to prevent incorrectly formatted
|
||||
## rules from making their way into prometheus and potentially preventing the container from starting
|
||||
@@ -1289,7 +1928,7 @@
|
||||
@@ -1289,8 +1988,8 @@
|
||||
patch:
|
||||
enabled: true
|
||||
image:
|
||||
- repository: jettech/kube-webhook-certgen
|
||||
- tag: v1.5.0
|
||||
+ repository: rancher/mirrored-jettech-kube-webhook-certgen
|
||||
tag: v1.5.0
|
||||
+ tag: v1.5.2
|
||||
sha: ""
|
||||
pullPolicy: IfNotPresent
|
||||
@@ -1428,13 +2067,13 @@
|
||||
resources: {}
|
||||
@@ -1301,6 +2000,16 @@
|
||||
nodeSelector: {}
|
||||
affinity: {}
|
||||
tolerations: []
|
||||
+
|
||||
+ ## SecurityContext holds pod-level security attributes and common container settings.
|
||||
+ ## This defaults to non root user with uid 2000 and gid 2000. *v1.PodSecurityContext false
|
||||
+ ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/
|
||||
+ ##
|
||||
+ securityContext:
|
||||
+ runAsGroup: 2000
|
||||
+ runAsNonRoot: true
|
||||
+ runAsUser: 2000
|
||||
+
|
||||
# Use certmanager to generate webhook certs
|
||||
certManager:
|
||||
enabled: false
|
||||
@@ -1428,13 +2137,13 @@
|
||||
|
||||
## Resource limits & requests
|
||||
##
|
||||
|
@ -879,31 +1105,53 @@
|
|||
|
||||
# Required for use in managed kubernetes clusters (such as AWS EKS) with custom CNI (such as calico),
|
||||
# because control-plane managed by AWS cannot communicate with pods' IP CIDR and admission webhooks are not working
|
||||
@@ -1487,7 +2126,7 @@
|
||||
@@ -1487,8 +2196,8 @@
|
||||
## Prometheus-operator image
|
||||
##
|
||||
image:
|
||||
- repository: quay.io/prometheus-operator/prometheus-operator
|
||||
- tag: v0.46.0
|
||||
+ repository: rancher/mirrored-prometheus-operator-prometheus-operator
|
||||
tag: v0.46.0
|
||||
+ tag: v0.48.0
|
||||
sha: ""
|
||||
pullPolicy: IfNotPresent
|
||||
@@ -1503,7 +2142,7 @@
|
||||
|
||||
@@ -1503,8 +2212,8 @@
|
||||
## Prometheus-config-reloader image to use for config and rule reloading
|
||||
##
|
||||
prometheusConfigReloaderImage:
|
||||
- repository: quay.io/prometheus-operator/prometheus-config-reloader
|
||||
- tag: v0.46.0
|
||||
+ repository: rancher/mirrored-prometheus-operator-prometheus-config-reloader
|
||||
tag: v0.46.0
|
||||
+ tag: v0.48.0
|
||||
sha: ""
|
||||
|
||||
@@ -1558,6 +2197,14 @@
|
||||
## Set the prometheus config reloader side-car CPU limit
|
||||
@@ -1535,6 +2244,7 @@
|
||||
serviceAccount:
|
||||
create: true
|
||||
name: ""
|
||||
+ annotations: {}
|
||||
|
||||
# Service for thanos service discovery on sidecar
|
||||
# Enable this can make Thanos Query can use
|
||||
@@ -1558,6 +2268,24 @@
|
||||
##
|
||||
nodePort: 30901
|
||||
|
||||
+ # Service for external access to sidecar
|
||||
+ # Enabling this creates a service to expose thanos-sidecar outside the cluster.
|
||||
+ thanosServiceExternal:
|
||||
+ enabled: false
|
||||
+ annotations: {}
|
||||
+ labels: {}
|
||||
+ portName: grpc
|
||||
+ port: 10901
|
||||
+ targetPort: "grpc"
|
||||
+
|
||||
+ ## Service type
|
||||
+ ##
|
||||
+ type: ClusterIP
|
||||
+ type: LoadBalancer
|
||||
+
|
||||
+ ## Port to expose on each node
|
||||
+ ##
|
||||
|
@ -912,7 +1160,7 @@
|
|||
## Configuration for Prometheus service
|
||||
##
|
||||
service:
|
||||
@@ -1570,7 +2217,7 @@
|
||||
@@ -1570,7 +2298,7 @@
|
||||
port: 9090
|
||||
|
||||
## To be used with a proxy extraContainer port
|
||||
|
@ -921,16 +1169,26 @@
|
|||
|
||||
## List of IP addresses at which the Prometheus server service is available
|
||||
## Ref: https://kubernetes.io/docs/user-guide/services/#external-ips
|
||||
@@ -1822,7 +2469,7 @@
|
||||
@@ -1819,11 +2547,16 @@
|
||||
##
|
||||
enableAdminAPI: false
|
||||
|
||||
+ # EnableFeatures API enables access to Prometheus disabled features.
|
||||
+ # ref: https://prometheus.io/docs/prometheus/latest/disabled_features/
|
||||
+ enableFeatures: []
|
||||
+ # - exemplar-storage
|
||||
+
|
||||
## Image of Prometheus.
|
||||
##
|
||||
image:
|
||||
- repository: quay.io/prometheus/prometheus
|
||||
- tag: v2.24.0
|
||||
+ repository: rancher/mirrored-prometheus-prometheus
|
||||
tag: v2.24.0
|
||||
+ tag: v2.27.1
|
||||
sha: ""
|
||||
|
||||
@@ -1885,6 +2532,11 @@
|
||||
## Tolerations for use with node taints
|
||||
@@ -1885,6 +2618,11 @@
|
||||
##
|
||||
externalUrl: ""
|
||||
|
||||
|
@ -942,7 +1200,7 @@
|
|||
## Define which Nodes the Pods are scheduled on.
|
||||
## ref: https://kubernetes.io/docs/user-guide/node-selection/
|
||||
##
|
||||
@@ -1917,7 +2569,7 @@
|
||||
@@ -1917,7 +2655,7 @@
|
||||
## prometheus resource to be created with selectors based on values in the helm deployment,
|
||||
## which will also match the PrometheusRule resources created
|
||||
##
|
||||
|
@ -951,7 +1209,7 @@
|
|||
|
||||
## PrometheusRules to be selected for target discovery.
|
||||
## If {}, select all PrometheusRules
|
||||
@@ -1942,7 +2594,7 @@
|
||||
@@ -1942,7 +2680,7 @@
|
||||
## prometheus resource to be created with selectors based on values in the helm deployment,
|
||||
## which will also match the servicemonitors created
|
||||
##
|
||||
|
@ -960,7 +1218,7 @@
|
|||
|
||||
## ServiceMonitors to be selected for target discovery.
|
||||
## If {}, select all ServiceMonitors
|
||||
@@ -1965,7 +2617,7 @@
|
||||
@@ -1965,7 +2703,7 @@
|
||||
## prometheus resource to be created with selectors based on values in the helm deployment,
|
||||
## which will also match the podmonitors created
|
||||
##
|
||||
|
@ -969,7 +1227,31 @@
|
|||
|
||||
## PodMonitors to be selected for target discovery.
|
||||
## If {}, select all PodMonitors
|
||||
@@ -2092,9 +2744,13 @@
|
||||
@@ -2044,7 +2782,7 @@
|
||||
##
|
||||
routePrefix: /
|
||||
|
||||
- ## Standard object’s metadata. More info: https://github.com/kubernetes/community/blob/master/contributors/devel/sig-architecture/api-conventions.md#metadata
|
||||
+ ## Standard object's metadata. More info: https://github.com/kubernetes/community/blob/master/contributors/devel/sig-architecture/api-conventions.md#metadata
|
||||
## Metadata Labels and Annotations gets propagated to the prometheus pods.
|
||||
##
|
||||
podMetadata: {}
|
||||
@@ -2081,20 +2819,28 @@
|
||||
## ref: https://github.com/prometheus-operator/prometheus-operator/blob/master/Documentation/api.md#remotereadspec
|
||||
remoteRead: []
|
||||
# - url: http://remote1/read
|
||||
+ ## additionalRemoteRead is appended to remoteRead
|
||||
+ additionalRemoteRead: []
|
||||
|
||||
## The remote_write spec configuration for Prometheus.
|
||||
## ref: https://github.com/prometheus-operator/prometheus-operator/blob/master/Documentation/api.md#remotewritespec
|
||||
remoteWrite: []
|
||||
# - url: http://remote1/push
|
||||
+ ## additionalRemoteWrite is appended to remoteWrite
|
||||
+ additionalRemoteWrite: []
|
||||
|
||||
## Enable/Disable Grafana dashboards provisioning for prometheus remote write feature
|
||||
remoteWriteDashboards: false
|
||||
|
||||
## Resource limits & requests
|
||||
##
|
||||
|
@ -986,7 +1268,7 @@
|
|||
|
||||
## Prometheus StorageSpec for persistent data
|
||||
## ref: https://github.com/prometheus-operator/prometheus-operator/blob/master/Documentation/user-guides/storage.md
|
||||
@@ -2117,7 +2773,13 @@
|
||||
@@ -2117,7 +2863,13 @@
|
||||
# medium: Memory
|
||||
|
||||
# Additional volumes on the output StatefulSet definition.
|
||||
|
@ -1001,7 +1283,7 @@
|
|||
|
||||
# Additional VolumeMounts on the output StatefulSet definition.
|
||||
volumeMounts: []
|
||||
@@ -2224,9 +2886,34 @@
|
||||
@@ -2224,9 +2976,34 @@
|
||||
##
|
||||
thanos: {}
|
||||
|
||||
|
@ -1037,7 +1319,7 @@
|
|||
|
||||
## InitContainers allows injecting additional initContainers. This is meant to allow doing some changes
|
||||
## (permissions, dir tree) on mounted volumes before starting prometheus
|
||||
@@ -2234,7 +2921,7 @@
|
||||
@@ -2234,7 +3011,7 @@
|
||||
|
||||
## PortName to use for Prometheus.
|
||||
##
|
||||
|
|
Loading…
Reference in New Issue