From 7ccd55bbd26d54190fc8761ed6e72e17a24c963a Mon Sep 17 00:00:00 2001
From: Florian Sesser <florian@private.storage>
Date: Wed, 31 Aug 2022 20:59:33 +0000
Subject: [PATCH] Monitoring: Backup: Daily backup duration dash: Barchart

... instead of connected lines default, also with working label for host

Refs privatestorageops#429
---
 .../server/grafana-dashboards/backups.json    | 32 ++++++++-----------
 1 file changed, 14 insertions(+), 18 deletions(-)

diff --git a/nixos/modules/monitoring/server/grafana-dashboards/backups.json b/nixos/modules/monitoring/server/grafana-dashboards/backups.json
index 29a2a140..10600a0d 100644
--- a/nixos/modules/monitoring/server/grafana-dashboards/backups.json
+++ b/nixos/modules/monitoring/server/grafana-dashboards/backups.json
@@ -632,29 +632,16 @@
           "custom": {
             "axisLabel": "",
             "axisPlacement": "auto",
-            "barAlignment": 0,
-            "drawStyle": "line",
-            "fillOpacity": 0,
+            "fillOpacity": 60,
             "gradientMode": "none",
             "hideFrom": {
               "legend": false,
               "tooltip": false,
               "viz": false
             },
-            "lineInterpolation": "linear",
             "lineWidth": 1,
-            "pointSize": 5,
             "scaleDistribution": {
               "type": "linear"
-            },
-            "showPoints": "auto",
-            "spanNulls": false,
-            "stacking": {
-              "group": "A",
-              "mode": "none"
-            },
-            "thresholdsStyle": {
-              "mode": "off"
             }
           },
           "mappings": [],
@@ -687,15 +674,24 @@
       },
       "id": 49,
       "options": {
+        "barRadius": 0,
+        "barWidth": 0.1,
+        "groupWidth": 0.7,
         "legend": {
           "calcs": [],
-          "displayMode": "list",
+          "displayMode": "hidden",
           "placement": "bottom"
         },
+        "orientation": "auto",
+        "showValue": "auto",
+        "stacking": "none",
         "tooltip": {
           "mode": "single",
           "sort": "none"
-        }
+        },
+        "xField": "host",
+        "xTickLabelRotation": -45,
+        "xTickLabelSpacing": 0
       },
       "pluginVersion": "8.4.7",
       "targets": [
@@ -738,10 +734,10 @@
           "options": {}
         }
       ],
-      "type": "timeseries"
+      "type": "barchart"
     }
   ],
-  "refresh": "1m",
+  "refresh": "5m",
   "schemaVersion": 35,
   "style": "dark",
   "tags": [],
-- 
GitLab