mirror of
https://github.com/carlosedp/cluster-monitoring.git
synced 2024-11-20 19:07:17 +01:00
34 lines
1.3 KiB
YAML
34 lines
1.3 KiB
YAML
apiVersion: v1
|
|
data:
|
|
config.yaml: |
|
|
resourceRules:
|
|
cpu:
|
|
containerQuery: sum(irate(container_cpu_usage_seconds_total{<<.LabelMatchers>>,container!="POD",container!="",pod!=""}[5m])) by (<<.GroupBy>>)
|
|
nodeQuery: sum(1 - irate(node_cpu_seconds_total{mode="idle"}[5m]) * on(namespace, pod) group_left(node) node_namespace_pod:kube_pod_info:{<<.LabelMatchers>>}) by (<<.GroupBy>>)
|
|
resources:
|
|
overrides:
|
|
node:
|
|
resource: node
|
|
namespace:
|
|
resource: namespace
|
|
pod:
|
|
resource: pod
|
|
containerLabel: container
|
|
memory:
|
|
containerQuery: sum(container_memory_working_set_bytes{<<.LabelMatchers>>,container!="POD",container!="",pod!=""}) by (<<.GroupBy>>)
|
|
nodeQuery: sum(node_memory_MemTotal_bytes{job="node-exporter",<<.LabelMatchers>>} - node_memory_MemAvailable_bytes{job="node-exporter",<<.LabelMatchers>>}) by (<<.GroupBy>>)
|
|
resources:
|
|
overrides:
|
|
instance:
|
|
resource: node
|
|
namespace:
|
|
resource: namespace
|
|
pod:
|
|
resource: pod
|
|
containerLabel: container
|
|
window: 5m
|
|
kind: ConfigMap
|
|
metadata:
|
|
name: adapter-config
|
|
namespace: monitoring
|