mirror of
https://github.com/monitoring-mixins/website.git
synced 2024-12-15 17:50:48 +00:00
assets,site/content: daily assets regeneration
This commit is contained in:
parent
982b8fc5d3
commit
a90f757c9e
2 changed files with 100 additions and 18 deletions
|
@ -537,12 +537,32 @@ groups:
|
||||||
)
|
)
|
||||||
record: cluster_namespace_deployment:container_cpu_usage_seconds_total:sum_rate
|
record: cluster_namespace_deployment:container_cpu_usage_seconds_total:sum_rate
|
||||||
- expr: |
|
- expr: |
|
||||||
|
# This recording rule is made compatible with the breaking changes introduced in kube-state-metrics v2
|
||||||
|
# that remove resource metrics, ref:
|
||||||
|
# - https://github.com/kubernetes/kube-state-metrics/blob/master/CHANGELOG.md#v200-alpha--2020-09-16
|
||||||
|
# - https://github.com/kubernetes/kube-state-metrics/pull/1004
|
||||||
|
#
|
||||||
|
# This is the old expression, compatible with kube-state-metrics < v2.0.0,
|
||||||
|
# where kube_pod_container_resource_requests_cpu_cores was removed:
|
||||||
|
(
|
||||||
sum by (cluster, namespace, deployment) (
|
sum by (cluster, namespace, deployment) (
|
||||||
label_replace(
|
label_replace(
|
||||||
kube_pod_container_resource_requests_cpu_cores,
|
kube_pod_container_resource_requests_cpu_cores,
|
||||||
"deployment", "$1", "pod", "(.*)-(?:([0-9]+)|([a-z0-9]+)-([a-z0-9]+))"
|
"deployment", "$1", "pod", "(.*)-(?:([0-9]+)|([a-z0-9]+)-([a-z0-9]+))"
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
)
|
||||||
|
or
|
||||||
|
# This expression is compatible with kube-state-metrics >= v1.4.0,
|
||||||
|
# where kube_pod_container_resource_requests was introduced.
|
||||||
|
(
|
||||||
|
sum by (cluster, namespace, deployment) (
|
||||||
|
label_replace(
|
||||||
|
kube_pod_container_resource_requests{resource="cpu"},
|
||||||
|
"deployment", "$1", "pod", "(.*)-(?:([0-9]+)|([a-z0-9]+)-([a-z0-9]+))"
|
||||||
|
)
|
||||||
|
)
|
||||||
|
)
|
||||||
record: cluster_namespace_deployment:kube_pod_container_resource_requests_cpu_cores:sum
|
record: cluster_namespace_deployment:kube_pod_container_resource_requests_cpu_cores:sum
|
||||||
- expr: |
|
- expr: |
|
||||||
ceil(
|
ceil(
|
||||||
|
@ -564,12 +584,32 @@ groups:
|
||||||
)
|
)
|
||||||
record: cluster_namespace_deployment:container_memory_usage_bytes:sum
|
record: cluster_namespace_deployment:container_memory_usage_bytes:sum
|
||||||
- expr: |
|
- expr: |
|
||||||
|
# This recording rule is made compatible with the breaking changes introduced in kube-state-metrics v2
|
||||||
|
# that remove resource metrics, ref:
|
||||||
|
# - https://github.com/kubernetes/kube-state-metrics/blob/master/CHANGELOG.md#v200-alpha--2020-09-16
|
||||||
|
# - https://github.com/kubernetes/kube-state-metrics/pull/1004
|
||||||
|
#
|
||||||
|
# This is the old expression, compatible with kube-state-metrics < v2.0.0,
|
||||||
|
# where kube_pod_container_resource_requests_memory_bytes was removed:
|
||||||
|
(
|
||||||
sum by (cluster, namespace, deployment) (
|
sum by (cluster, namespace, deployment) (
|
||||||
label_replace(
|
label_replace(
|
||||||
kube_pod_container_resource_requests_memory_bytes,
|
kube_pod_container_resource_requests_memory_bytes,
|
||||||
"deployment", "$1", "pod", "(.*)-(?:([0-9]+)|([a-z0-9]+)-([a-z0-9]+))"
|
"deployment", "$1", "pod", "(.*)-(?:([0-9]+)|([a-z0-9]+)-([a-z0-9]+))"
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
)
|
||||||
|
or
|
||||||
|
# This expression is compatible with kube-state-metrics >= v1.4.0,
|
||||||
|
# where kube_pod_container_resource_requests was introduced.
|
||||||
|
(
|
||||||
|
sum by (cluster, namespace, deployment) (
|
||||||
|
label_replace(
|
||||||
|
kube_pod_container_resource_requests{resource="memory"},
|
||||||
|
"deployment", "$1", "pod", "(.*)-(?:([0-9]+)|([a-z0-9]+)-([a-z0-9]+))"
|
||||||
|
)
|
||||||
|
)
|
||||||
|
)
|
||||||
record: cluster_namespace_deployment:kube_pod_container_resource_requests_memory_bytes:sum
|
record: cluster_namespace_deployment:kube_pod_container_resource_requests_memory_bytes:sum
|
||||||
- expr: |
|
- expr: |
|
||||||
ceil(
|
ceil(
|
||||||
|
|
|
@ -2206,16 +2206,37 @@ expr: |
|
||||||
record: cluster_namespace_deployment:container_cpu_usage_seconds_total:sum_rate
|
record: cluster_namespace_deployment:container_cpu_usage_seconds_total:sum_rate
|
||||||
{{< /code >}}
|
{{< /code >}}
|
||||||
|
|
||||||
##### cluster_namespace_deployment:kube_pod_container_resource_requests_cpu_cores:sum
|
#####
|
||||||
|
cluster_namespace_deployment:kube_pod_container_resource_requests_cpu_cores:sum
|
||||||
|
|
||||||
{{< code lang="yaml" >}}
|
{{< code lang="yaml" >}}
|
||||||
expr: |
|
expr: |
|
||||||
|
# This recording rule is made compatible with the breaking changes introduced in kube-state-metrics v2
|
||||||
|
# that remove resource metrics, ref:
|
||||||
|
# - https://github.com/kubernetes/kube-state-metrics/blob/master/CHANGELOG.md#v200-alpha--2020-09-16
|
||||||
|
# - https://github.com/kubernetes/kube-state-metrics/pull/1004
|
||||||
|
#
|
||||||
|
# This is the old expression, compatible with kube-state-metrics < v2.0.0,
|
||||||
|
# where kube_pod_container_resource_requests_cpu_cores was removed:
|
||||||
|
(
|
||||||
sum by (cluster, namespace, deployment) (
|
sum by (cluster, namespace, deployment) (
|
||||||
label_replace(
|
label_replace(
|
||||||
kube_pod_container_resource_requests_cpu_cores,
|
kube_pod_container_resource_requests_cpu_cores,
|
||||||
"deployment", "$1", "pod", "(.*)-(?:([0-9]+)|([a-z0-9]+)-([a-z0-9]+))"
|
"deployment", "$1", "pod", "(.*)-(?:([0-9]+)|([a-z0-9]+)-([a-z0-9]+))"
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
)
|
||||||
|
or
|
||||||
|
# This expression is compatible with kube-state-metrics >= v1.4.0,
|
||||||
|
# where kube_pod_container_resource_requests was introduced.
|
||||||
|
(
|
||||||
|
sum by (cluster, namespace, deployment) (
|
||||||
|
label_replace(
|
||||||
|
kube_pod_container_resource_requests{resource="cpu"},
|
||||||
|
"deployment", "$1", "pod", "(.*)-(?:([0-9]+)|([a-z0-9]+)-([a-z0-9]+))"
|
||||||
|
)
|
||||||
|
)
|
||||||
|
)
|
||||||
record: cluster_namespace_deployment:kube_pod_container_resource_requests_cpu_cores:sum
|
record: cluster_namespace_deployment:kube_pod_container_resource_requests_cpu_cores:sum
|
||||||
{{< /code >}}
|
{{< /code >}}
|
||||||
|
|
||||||
|
@ -2248,16 +2269,37 @@ expr: |
|
||||||
record: cluster_namespace_deployment:container_memory_usage_bytes:sum
|
record: cluster_namespace_deployment:container_memory_usage_bytes:sum
|
||||||
{{< /code >}}
|
{{< /code >}}
|
||||||
|
|
||||||
##### cluster_namespace_deployment:kube_pod_container_resource_requests_memory_bytes:sum
|
#####
|
||||||
|
cluster_namespace_deployment:kube_pod_container_resource_requests_memory_bytes:sum
|
||||||
|
|
||||||
{{< code lang="yaml" >}}
|
{{< code lang="yaml" >}}
|
||||||
expr: |
|
expr: |
|
||||||
|
# This recording rule is made compatible with the breaking changes introduced in kube-state-metrics v2
|
||||||
|
# that remove resource metrics, ref:
|
||||||
|
# - https://github.com/kubernetes/kube-state-metrics/blob/master/CHANGELOG.md#v200-alpha--2020-09-16
|
||||||
|
# - https://github.com/kubernetes/kube-state-metrics/pull/1004
|
||||||
|
#
|
||||||
|
# This is the old expression, compatible with kube-state-metrics < v2.0.0,
|
||||||
|
# where kube_pod_container_resource_requests_memory_bytes was removed:
|
||||||
|
(
|
||||||
sum by (cluster, namespace, deployment) (
|
sum by (cluster, namespace, deployment) (
|
||||||
label_replace(
|
label_replace(
|
||||||
kube_pod_container_resource_requests_memory_bytes,
|
kube_pod_container_resource_requests_memory_bytes,
|
||||||
"deployment", "$1", "pod", "(.*)-(?:([0-9]+)|([a-z0-9]+)-([a-z0-9]+))"
|
"deployment", "$1", "pod", "(.*)-(?:([0-9]+)|([a-z0-9]+)-([a-z0-9]+))"
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
)
|
||||||
|
or
|
||||||
|
# This expression is compatible with kube-state-metrics >= v1.4.0,
|
||||||
|
# where kube_pod_container_resource_requests was introduced.
|
||||||
|
(
|
||||||
|
sum by (cluster, namespace, deployment) (
|
||||||
|
label_replace(
|
||||||
|
kube_pod_container_resource_requests{resource="memory"},
|
||||||
|
"deployment", "$1", "pod", "(.*)-(?:([0-9]+)|([a-z0-9]+)-([a-z0-9]+))"
|
||||||
|
)
|
||||||
|
)
|
||||||
|
)
|
||||||
record: cluster_namespace_deployment:kube_pod_container_resource_requests_memory_bytes:sum
|
record: cluster_namespace_deployment:kube_pod_container_resource_requests_memory_bytes:sum
|
||||||
{{< /code >}}
|
{{< /code >}}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue