From 3ef5db455a46095196191ed10509d000a0f29dc1 Mon Sep 17 00:00:00 2001 From: Benedikt Peetz Date: Sun, 19 Jul 2026 03:14:35 +0200 Subject: {modules,test}/monitoring: Init basic version --- modules/by-name/mo/monitoring/module.nix | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 modules/by-name/mo/monitoring/module.nix (limited to 'modules/by-name/mo/monitoring/module.nix') diff --git a/modules/by-name/mo/monitoring/module.nix b/modules/by-name/mo/monitoring/module.nix new file mode 100644 index 0000000..e0fc5db --- /dev/null +++ b/modules/by-name/mo/monitoring/module.nix @@ -0,0 +1,31 @@ +# Heavily inspired by: +# https://github.com/ibizaman/selfhostblocks/blob/989865eb519e3fc3e8a803c374775451c47a29c8/modules/blocks/monitoring.nix +{ + lib, + config, + ... +}: let + cfg = config.vhack.monitoring; +in { + imports = [ + ./components/loki.nix + # ./components/perses.nix + ./components/grafana.nix + ./components/scrutiny.nix + ./components/prometheus.nix + ]; + + options.vhack.monitoring = { + enable = lib.mkEnableOption "monitoring defaults"; + }; + + config.vhack.monitoring = lib.mkIf cfg.enable { + grafana.enable = true; + + loki.enable = true; + + prometheus.enable = true; + + scrutiny. enable = true; + }; +} -- cgit v1.3.1