diff options
Diffstat (limited to 'modules/xnet/monitoring/grafana.nix')
| -rw-r--r-- | modules/xnet/monitoring/grafana.nix | 33 |
1 files changed, 21 insertions, 12 deletions
diff --git a/modules/xnet/monitoring/grafana.nix b/modules/xnet/monitoring/grafana.nix index e95318d..a8712f0 100644 --- a/modules/xnet/monitoring/grafana.nix +++ b/modules/xnet/monitoring/grafana.nix @@ -1,4 +1,9 @@ -{ config, pkgs, lib, ... }: +{ + config, + pkgs, + lib, + ... +}: let inherit (lib) mkOption mkIf types; @@ -18,18 +23,22 @@ in config = mkIf hostGrafana { services.grafana.provision = { enable = true; - datasources.settings.datasources = [{ - name = "Prometheus"; - type = "prometheus"; - url = "http://localhost:9090"; - access = "proxy"; - editable = false; - }]; + datasources.settings.datasources = [ + { + name = "Prometheus"; + type = "prometheus"; + url = "http://localhost:9090"; + access = "proxy"; + editable = false; + } + ]; - dashboards.settings.providers = [{ - name = "Fetched Dashboards"; - options.path = "/etc/grafana/dashboards"; - }]; + dashboards.settings.providers = [ + { + name = "Fetched Dashboards"; + options.path = "/etc/grafana/dashboards"; + } + ]; }; environment.etc = { |
