monitoring: panel para el runner, Prometheus y Uptime Kuma
Los tres puntos ciegos que quedaban. El gitea-runner se dejó fuera del panel de
gitea a propósito, porque si cae se paran los builds pero Gitea sigue sirviendo
y pintar "gitea: Down" sería una falsa alarma; pero su caída es de las mudas y
merecía el suyo. Prometheus y Uptime Kuma se quedaron sin representar cuando el
panel "grafana" pasó a mirar sólo a su deployment en vez de a todo el namespace
monitoring (5d0078c).
Misma forma que los otros doce, con el selector acotado al workload concreto;
para Prometheus, que es un StatefulSet, la rama de deployment sale vacía y
resuelve la de statefulset. La fila de servicios estaba llena, así que se abre
una tercera y todo lo de debajo baja 4 filas de rejilla.
Verificado antes de escribirlo: las tres consultas dan 1 ahora y 0 con escasez
de réplicas simulada. Y después, los 15 estados a través del proxy de datasource
de Grafana, no consultando yo a Prometheus por otro lado.
Nota conocida, no un fallo: si kube-state-metrics cae, los 15 paneles se ponen
en rojo a la vez, porque todos dependen de sus métricas. Un tablero entero en
rojo hay que leerlo como "se ha caído el que mide", no como quince caídas.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -1375,13 +1375,277 @@ data:
|
|||||||
"title": "searxng",
|
"title": "searxng",
|
||||||
"type": "stat"
|
"type": "stat"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"datasource": {
|
||||||
|
"type": "prometheus",
|
||||||
|
"uid": "prometheus"
|
||||||
|
},
|
||||||
|
"fieldConfig": {
|
||||||
|
"defaults": {
|
||||||
|
"color": {
|
||||||
|
"mode": "thresholds"
|
||||||
|
},
|
||||||
|
"mappings": [
|
||||||
|
{
|
||||||
|
"options": {
|
||||||
|
"0": {
|
||||||
|
"color": "red",
|
||||||
|
"index": 0,
|
||||||
|
"text": "Down"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"type": "value"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"options": {
|
||||||
|
"from": 1,
|
||||||
|
"result": {
|
||||||
|
"color": "green",
|
||||||
|
"index": 1,
|
||||||
|
"text": "Running"
|
||||||
|
},
|
||||||
|
"to": null
|
||||||
|
},
|
||||||
|
"type": "range"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"thresholds": {
|
||||||
|
"mode": "absolute",
|
||||||
|
"steps": [
|
||||||
|
{
|
||||||
|
"color": "red",
|
||||||
|
"value": null
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"color": "green",
|
||||||
|
"value": 1
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"unit": "short"
|
||||||
|
},
|
||||||
|
"overrides": []
|
||||||
|
},
|
||||||
|
"gridPos": {
|
||||||
|
"h": 4,
|
||||||
|
"w": 4,
|
||||||
|
"x": 0,
|
||||||
|
"y": 18
|
||||||
|
},
|
||||||
|
"id": 34,
|
||||||
|
"options": {
|
||||||
|
"colorMode": "background",
|
||||||
|
"graphMode": "none",
|
||||||
|
"justifyMode": "auto",
|
||||||
|
"orientation": "auto",
|
||||||
|
"reduceOptions": {
|
||||||
|
"calcs": [
|
||||||
|
"lastNotNull"
|
||||||
|
],
|
||||||
|
"fields": "",
|
||||||
|
"values": false
|
||||||
|
},
|
||||||
|
"textMode": "auto"
|
||||||
|
},
|
||||||
|
"pluginVersion": "12.4.2",
|
||||||
|
"targets": [
|
||||||
|
{
|
||||||
|
"datasource": {
|
||||||
|
"type": "prometheus",
|
||||||
|
"uid": "prometheus"
|
||||||
|
},
|
||||||
|
"expr": "min((kube_deployment_status_replicas_available{namespace=\"gitea\",deployment=\"gitea-runner\"} >= bool 1) or (kube_statefulset_status_replicas_ready{namespace=\"gitea\",deployment=\"gitea-runner\"} >= bool 1)) or vector(0)",
|
||||||
|
"instant": true,
|
||||||
|
"legendFormat": "gitea-runner",
|
||||||
|
"refId": "A"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"title": "gitea-runner",
|
||||||
|
"type": "stat"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"datasource": {
|
||||||
|
"type": "prometheus",
|
||||||
|
"uid": "prometheus"
|
||||||
|
},
|
||||||
|
"fieldConfig": {
|
||||||
|
"defaults": {
|
||||||
|
"color": {
|
||||||
|
"mode": "thresholds"
|
||||||
|
},
|
||||||
|
"mappings": [
|
||||||
|
{
|
||||||
|
"options": {
|
||||||
|
"0": {
|
||||||
|
"color": "red",
|
||||||
|
"index": 0,
|
||||||
|
"text": "Down"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"type": "value"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"options": {
|
||||||
|
"from": 1,
|
||||||
|
"result": {
|
||||||
|
"color": "green",
|
||||||
|
"index": 1,
|
||||||
|
"text": "Running"
|
||||||
|
},
|
||||||
|
"to": null
|
||||||
|
},
|
||||||
|
"type": "range"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"thresholds": {
|
||||||
|
"mode": "absolute",
|
||||||
|
"steps": [
|
||||||
|
{
|
||||||
|
"color": "red",
|
||||||
|
"value": null
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"color": "green",
|
||||||
|
"value": 1
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"unit": "short"
|
||||||
|
},
|
||||||
|
"overrides": []
|
||||||
|
},
|
||||||
|
"gridPos": {
|
||||||
|
"h": 4,
|
||||||
|
"w": 4,
|
||||||
|
"x": 4,
|
||||||
|
"y": 18
|
||||||
|
},
|
||||||
|
"id": 35,
|
||||||
|
"options": {
|
||||||
|
"colorMode": "background",
|
||||||
|
"graphMode": "none",
|
||||||
|
"justifyMode": "auto",
|
||||||
|
"orientation": "auto",
|
||||||
|
"reduceOptions": {
|
||||||
|
"calcs": [
|
||||||
|
"lastNotNull"
|
||||||
|
],
|
||||||
|
"fields": "",
|
||||||
|
"values": false
|
||||||
|
},
|
||||||
|
"textMode": "auto"
|
||||||
|
},
|
||||||
|
"pluginVersion": "12.4.2",
|
||||||
|
"targets": [
|
||||||
|
{
|
||||||
|
"datasource": {
|
||||||
|
"type": "prometheus",
|
||||||
|
"uid": "prometheus"
|
||||||
|
},
|
||||||
|
"expr": "min((kube_deployment_status_replicas_available{namespace=\"monitoring\",statefulset=\"prometheus-kube-prometheus-stack-prometheus\"} >= bool 1) or (kube_statefulset_status_replicas_ready{namespace=\"monitoring\",statefulset=\"prometheus-kube-prometheus-stack-prometheus\"} >= bool 1)) or vector(0)",
|
||||||
|
"instant": true,
|
||||||
|
"legendFormat": "prometheus",
|
||||||
|
"refId": "A"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"title": "prometheus",
|
||||||
|
"type": "stat"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"datasource": {
|
||||||
|
"type": "prometheus",
|
||||||
|
"uid": "prometheus"
|
||||||
|
},
|
||||||
|
"fieldConfig": {
|
||||||
|
"defaults": {
|
||||||
|
"color": {
|
||||||
|
"mode": "thresholds"
|
||||||
|
},
|
||||||
|
"mappings": [
|
||||||
|
{
|
||||||
|
"options": {
|
||||||
|
"0": {
|
||||||
|
"color": "red",
|
||||||
|
"index": 0,
|
||||||
|
"text": "Down"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"type": "value"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"options": {
|
||||||
|
"from": 1,
|
||||||
|
"result": {
|
||||||
|
"color": "green",
|
||||||
|
"index": 1,
|
||||||
|
"text": "Running"
|
||||||
|
},
|
||||||
|
"to": null
|
||||||
|
},
|
||||||
|
"type": "range"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"thresholds": {
|
||||||
|
"mode": "absolute",
|
||||||
|
"steps": [
|
||||||
|
{
|
||||||
|
"color": "red",
|
||||||
|
"value": null
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"color": "green",
|
||||||
|
"value": 1
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"unit": "short"
|
||||||
|
},
|
||||||
|
"overrides": []
|
||||||
|
},
|
||||||
|
"gridPos": {
|
||||||
|
"h": 4,
|
||||||
|
"w": 4,
|
||||||
|
"x": 8,
|
||||||
|
"y": 18
|
||||||
|
},
|
||||||
|
"id": 36,
|
||||||
|
"options": {
|
||||||
|
"colorMode": "background",
|
||||||
|
"graphMode": "none",
|
||||||
|
"justifyMode": "auto",
|
||||||
|
"orientation": "auto",
|
||||||
|
"reduceOptions": {
|
||||||
|
"calcs": [
|
||||||
|
"lastNotNull"
|
||||||
|
],
|
||||||
|
"fields": "",
|
||||||
|
"values": false
|
||||||
|
},
|
||||||
|
"textMode": "auto"
|
||||||
|
},
|
||||||
|
"pluginVersion": "12.4.2",
|
||||||
|
"targets": [
|
||||||
|
{
|
||||||
|
"datasource": {
|
||||||
|
"type": "prometheus",
|
||||||
|
"uid": "prometheus"
|
||||||
|
},
|
||||||
|
"expr": "min((kube_deployment_status_replicas_available{namespace=\"monitoring\",deployment=\"uptime-kuma\"} >= bool 1) or (kube_statefulset_status_replicas_ready{namespace=\"monitoring\",deployment=\"uptime-kuma\"} >= bool 1)) or vector(0)",
|
||||||
|
"instant": true,
|
||||||
|
"legendFormat": "uptime-kuma",
|
||||||
|
"refId": "A"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"title": "uptime-kuma",
|
||||||
|
"type": "stat"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"collapsed": false,
|
"collapsed": false,
|
||||||
"gridPos": {
|
"gridPos": {
|
||||||
"h": 1,
|
"h": 1,
|
||||||
"w": 24,
|
"w": 24,
|
||||||
"x": 0,
|
"x": 0,
|
||||||
"y": 18
|
"y": 22
|
||||||
},
|
},
|
||||||
"id": 18,
|
"id": 18,
|
||||||
"panels": [],
|
"panels": [],
|
||||||
@@ -1417,7 +1681,7 @@ data:
|
|||||||
"h": 8,
|
"h": 8,
|
||||||
"w": 12,
|
"w": 12,
|
||||||
"x": 0,
|
"x": 0,
|
||||||
"y": 19
|
"y": 23
|
||||||
},
|
},
|
||||||
"id": 19,
|
"id": 19,
|
||||||
"options": {
|
"options": {
|
||||||
@@ -1479,7 +1743,7 @@ data:
|
|||||||
"h": 8,
|
"h": 8,
|
||||||
"w": 12,
|
"w": 12,
|
||||||
"x": 12,
|
"x": 12,
|
||||||
"y": 19
|
"y": 23
|
||||||
},
|
},
|
||||||
"id": 20,
|
"id": 20,
|
||||||
"options": {
|
"options": {
|
||||||
@@ -1518,7 +1782,7 @@ data:
|
|||||||
"h": 1,
|
"h": 1,
|
||||||
"w": 24,
|
"w": 24,
|
||||||
"x": 0,
|
"x": 0,
|
||||||
"y": 27
|
"y": 31
|
||||||
},
|
},
|
||||||
"id": 30,
|
"id": 30,
|
||||||
"panels": [],
|
"panels": [],
|
||||||
@@ -1553,7 +1817,7 @@ data:
|
|||||||
"h": 8,
|
"h": 8,
|
||||||
"w": 8,
|
"w": 8,
|
||||||
"x": 0,
|
"x": 0,
|
||||||
"y": 28
|
"y": 32
|
||||||
},
|
},
|
||||||
"id": 31,
|
"id": 31,
|
||||||
"options": {
|
"options": {
|
||||||
@@ -1613,7 +1877,7 @@ data:
|
|||||||
"h": 8,
|
"h": 8,
|
||||||
"w": 8,
|
"w": 8,
|
||||||
"x": 8,
|
"x": 8,
|
||||||
"y": 28
|
"y": 32
|
||||||
},
|
},
|
||||||
"id": 32,
|
"id": 32,
|
||||||
"options": {
|
"options": {
|
||||||
@@ -1680,7 +1944,7 @@ data:
|
|||||||
"h": 8,
|
"h": 8,
|
||||||
"w": 8,
|
"w": 8,
|
||||||
"x": 16,
|
"x": 16,
|
||||||
"y": 28
|
"y": 32
|
||||||
},
|
},
|
||||||
"id": 33,
|
"id": 33,
|
||||||
"options": {
|
"options": {
|
||||||
@@ -1728,6 +1992,6 @@ data:
|
|||||||
"timezone": "browser",
|
"timezone": "browser",
|
||||||
"title": "ChemaVX Homelab Overview",
|
"title": "ChemaVX Homelab Overview",
|
||||||
"uid": "chemavx-homelab-v1",
|
"uid": "chemavx-homelab-v1",
|
||||||
"version": 6,
|
"version": 7,
|
||||||
"weekStart": ""
|
"weekStart": ""
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user