devops/grafana/grafana-dash-provisioning.yaml

53 lines
1.2 KiB
YAML

apiVersion: v1
kind: ConfigMap
metadata:
name: grafana-dash-provisioning
namespace: default
data:
dashboards.yml: |
apiVersion: 1
providers:
- name: 'Default'
orgId: 1
type: file
disableDeletion: false
editable: true
options:
path: /var/lib/grafana/dashboards
---
apiVersion: v1
kind: ConfigMap
metadata:
name: grafana-dashboard-aserver
namespace: default
data:
aserver-dashboard.json: |
{
"id": null,
"uid": "aserver-qps",
"title": "AServer Requests",
"timezone": "browser",
"schemaVersion": 38,
"version": 1,
"editable": true,
"style": "dark",
"time": { "from": "now-15m", "to": "now" },
"panels": [
{
"type": "timeseries",
"title": "Requests per second by endpoint",
"gridPos": { "x": 0, "y": 0, "w": 24, "h": 8 },
"targets": [
{
"expr": "sum by (endpoint) (rate(aserver_http_requests_total[1m]))",
"legendFormat": "{{endpoint}}",
"refId": "A",
"datasource": { "type": "prometheus", "uid": "Prometheus" }
}
]
}
]
}