|
1 | | -apiVersion: perses.dev/v1alpha1 |
| 1 | +apiVersion: perses.dev/v1alpha2 |
2 | 2 | kind: PersesDashboard |
3 | 3 | metadata: |
4 | 4 | name: cluster-overview |
5 | 5 | namespace: perses-example |
6 | 6 | spec: |
7 | | - display: |
8 | | - name: Cluster Overview |
9 | | - panels: |
10 | | - "0_0": |
11 | | - kind: Panel |
12 | | - spec: |
13 | | - display: |
14 | | - name: CPU |
15 | | - plugin: |
16 | | - kind: StatChart |
17 | | - spec: |
18 | | - calculation: mean |
19 | | - format: |
20 | | - unit: percent-decimal |
21 | | - thresholds: |
22 | | - steps: |
23 | | - - color: green |
24 | | - value: 0 |
25 | | - - color: red |
26 | | - value: 80 |
27 | | - queries: |
28 | | - - kind: TimeSeriesQuery |
| 7 | + config: |
| 8 | + display: |
| 9 | + name: Cluster Overview |
| 10 | + panels: |
| 11 | + "0_0": |
| 12 | + kind: Panel |
| 13 | + spec: |
| 14 | + display: |
| 15 | + name: CPU |
| 16 | + plugin: |
| 17 | + kind: StatChart |
29 | 18 | spec: |
30 | | - plugin: |
31 | | - kind: PrometheusTimeSeriesQuery |
32 | | - spec: |
33 | | - datasource: |
34 | | - kind: PrometheusDatasource |
35 | | - query: cluster:node_cpu:ratio_rate5m{} |
36 | | - "0_1": |
37 | | - kind: Panel |
38 | | - spec: |
39 | | - display: |
40 | | - name: Memory |
41 | | - plugin: |
42 | | - kind: StatChart |
43 | | - spec: |
44 | | - calculation: mean |
45 | | - format: |
46 | | - unit: percent-decimal |
47 | | - thresholds: |
48 | | - steps: |
49 | | - - color: green |
50 | | - value: 0 |
51 | | - - color: red |
52 | | - value: 80 |
53 | | - queries: |
54 | | - - kind: TimeSeriesQuery |
| 19 | + calculation: mean |
| 20 | + format: |
| 21 | + unit: percent-decimal |
| 22 | + thresholds: |
| 23 | + steps: |
| 24 | + - color: green |
| 25 | + value: 0 |
| 26 | + - color: red |
| 27 | + value: 80 |
| 28 | + queries: |
| 29 | + - kind: TimeSeriesQuery |
| 30 | + spec: |
| 31 | + plugin: |
| 32 | + kind: PrometheusTimeSeriesQuery |
| 33 | + spec: |
| 34 | + datasource: |
| 35 | + kind: PrometheusDatasource |
| 36 | + query: cluster:node_cpu:ratio_rate5m{} |
| 37 | + "0_1": |
| 38 | + kind: Panel |
| 39 | + spec: |
| 40 | + display: |
| 41 | + name: Memory |
| 42 | + plugin: |
| 43 | + kind: StatChart |
55 | 44 | spec: |
56 | | - plugin: |
57 | | - kind: PrometheusTimeSeriesQuery |
58 | | - spec: |
59 | | - datasource: |
60 | | - kind: PrometheusDatasource |
61 | | - query: 1 - sum(:node_memory_MemAvailable_bytes:sum) / sum(node_memory_MemTotal_bytes{job="node-exporter"}) |
62 | | - "0_2": |
63 | | - kind: Panel |
64 | | - spec: |
65 | | - display: |
66 | | - name: Welcome to Perses dashboards |
67 | | - plugin: |
68 | | - kind: Markdown |
69 | | - spec: |
70 | | - text: |- |
71 | | - This is a very simple dashboard which displays the overall |
72 | | - utilization of CPU and memory in the cluster based on the metrics |
73 | | - collected by the in-cluster monitoring stack. |
| 45 | + calculation: mean |
| 46 | + format: |
| 47 | + unit: percent-decimal |
| 48 | + thresholds: |
| 49 | + steps: |
| 50 | + - color: green |
| 51 | + value: 0 |
| 52 | + - color: red |
| 53 | + value: 80 |
| 54 | + queries: |
| 55 | + - kind: TimeSeriesQuery |
| 56 | + spec: |
| 57 | + plugin: |
| 58 | + kind: PrometheusTimeSeriesQuery |
| 59 | + spec: |
| 60 | + datasource: |
| 61 | + kind: PrometheusDatasource |
| 62 | + query: 1 - sum(:node_memory_MemAvailable_bytes:sum) / sum(node_memory_MemTotal_bytes{job="node-exporter"}) |
| 63 | + "0_2": |
| 64 | + kind: Panel |
| 65 | + spec: |
| 66 | + display: |
| 67 | + name: Welcome to Perses dashboards |
| 68 | + plugin: |
| 69 | + kind: Markdown |
| 70 | + spec: |
| 71 | + text: |- |
| 72 | + This is a very simple dashboard which displays the overall |
| 73 | + utilization of CPU and memory in the cluster based on the metrics |
| 74 | + collected by the in-cluster monitoring stack. |
74 | 75 |
|
75 | | - Check the [Observability Operator](https://github.com/rhobs/observability-operator) repository for more examples. |
76 | | - layouts: |
77 | | - - kind: Grid |
78 | | - spec: |
79 | | - display: |
80 | | - title: Overview |
81 | | - collapse: |
82 | | - open: true |
83 | | - items: |
84 | | - - x: 0 |
85 | | - "y": 1 |
86 | | - width: 8 |
87 | | - height: 6 |
88 | | - content: |
89 | | - $ref: "#/spec/panels/0_2" |
90 | | - - x: 8 |
91 | | - "y": 1 |
92 | | - width: 4 |
93 | | - height: 6 |
94 | | - content: |
95 | | - $ref: "#/spec/panels/0_0" |
96 | | - - x: 12 |
97 | | - "y": 1 |
98 | | - width: 4 |
99 | | - height: 6 |
100 | | - content: |
101 | | - $ref: "#/spec/panels/0_1" |
102 | | - duration: 1h |
| 76 | + Check the [Observability Operator](https://github.com/rhobs/observability-operator) repository for more examples. |
| 77 | + layouts: |
| 78 | + - kind: Grid |
| 79 | + spec: |
| 80 | + display: |
| 81 | + title: Overview |
| 82 | + collapse: |
| 83 | + open: true |
| 84 | + items: |
| 85 | + - x: 0 |
| 86 | + "y": 1 |
| 87 | + width: 8 |
| 88 | + height: 6 |
| 89 | + content: |
| 90 | + $ref: "#/spec/panels/0_2" |
| 91 | + - x: 8 |
| 92 | + "y": 1 |
| 93 | + width: 4 |
| 94 | + height: 6 |
| 95 | + content: |
| 96 | + $ref: "#/spec/panels/0_0" |
| 97 | + - x: 12 |
| 98 | + "y": 1 |
| 99 | + width: 4 |
| 100 | + height: 6 |
| 101 | + content: |
| 102 | + $ref: "#/spec/panels/0_1" |
| 103 | + duration: 1h |
0 commit comments