You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: docs/grafana.md
+20-4
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
### Grafana Dashboard Generation Option
2
2
3
-
The `-g, --gf_dashboard` command line option is designed to automate the generation of Grafana dashboards with all it's rules from your YAML configuration files. This feature is currently in a **work-in-progress (WIP)** stage. When using this option, it is important to note the following specifics:
3
+
The `-g, --gf_dashboard` command line option is designed to automate the generation of Grafana dashboards with all it's rules from your YAML configuration files. When using this option, it is important to note the following specifics:
4
4
5
5

6
6
@@ -10,16 +10,32 @@ The `-g, --gf_dashboard` command line option is designed to automate the generat
10
10
- All trafic is outgoing metric
11
11
12
12
#### Compatibility
13
-
-**Grafana Version:**This option is tailored to work optimally with Grafana version **10.3.5**. Buggy from 10.4 upwords
14
-
-**Plugin Requirement:** It requires the Flowcharting plugin version **1.0.0.e**, which is available via a specific fork maintained by [skyfrank on GitHub](https://github.com/skyfrank/grafana-flowcharting). This plugin is essential for rendering the custom visualizations generated by the script. Lower version also work, but this one is recommended
13
+
-**Grafana Version:**Works optimally with Grafana version **>10.0.0**. Recomendation: **11.2.0**.
14
+
-**Plugin Requirement:** It requires the Flowcplugin [Flow plugin](https://grafana.com/grafana/plugins/andrewbmchugh-flow-panel). This plugin is essential for rendering the custom visualizations generated by the script.
15
15
16
-
####Usage
16
+
### Usage
17
17
To generate a dashboard, execute the following command:
Ensure that you replace `<path_to_your_yaml_file>` with the actual path to your YAML configuration file. Use it with grafana_dark or your own grafana compatible theme.
22
22
23
+
When the `-g` flag is used, the script generates the following:
24
+
1. Grafana dashboard JSON file
25
+
2. Panel YAML configuration file
26
+
3. draw.io diagram
27
+
28
+
#### To export the diagram as an SVG:
29
+
To get a full guide: [https://github.com/andymchugh/andrewbmchugh-flow-panel/blob/main/src/README.md#using-drawio-to-create-your-svg](https://github.com/andymchugh/andrewbmchugh-flow-panel/blob/main/src/README.md#using-drawio-to-create-your-svg)
30
+
1. Open the generated draw.io diagram using the draw.io application with the svgdata plugin enabled, or use the online version at [https://app.diagrams.net/?p=svgdata](https://app.diagrams.net/?p=svgdata).
31
+
2. Go to File -> Export -> SVG to export the diagram as an SVG file.
32
+
33
+
The generated dashboard JSON will include the panel configuration but without the SVG data. To complete the dashboard, you need to either:
34
+
- Copy and paste the SVG data into the designated SVG box in the Grafana dashboard editor.
35
+
- Upload the SVG file to a hosting service and reference the URL in the Grafana dashboard editor.
36
+
37
+
By following these steps, you can generate a complete Grafana dashboard with the diagram, panel configuration, and dashboard JSON file.
38
+
23
39
#### Current Limitations
24
40
-**Hardcoded Queries:** Currently, the dashboard queries are hardcoded and are specifically optimized for Nokia's SRLinux and SROS platforms. This means they may not be directly applicable to other environments without modifications.
25
41
-**Data Sources:** The dashboard assumes specific data sources (Prometheus) are already configured in your Grafana instance that align with the hardcoded queries.
0 commit comments