summary refs log tree commit diff
path: root/services
diff options
context:
space:
mode:
authorMel <einebeere@gmail.com>2024-12-19 21:04:44 +0100
committerMel <einebeere@gmail.com>2024-12-19 21:19:17 +0100
commit5083c75163079244ab2f3f4eca1c9d514c2bbf03 (patch)
tree305d7ca1e6dc31dd6568c667125780f5af71a0eb /services
parent52e20b282cbc817edcb6743bafc640c34ec1daa6 (diff)
downloadnetwork-5083c75163079244ab2f3f4eca1c9d514c2bbf03.tar.zst
network-5083c75163079244ab2f3f4eca1c9d514c2bbf03.zip
Foundation module for monitoring options
Signed-off-by: Mel <einebeere@gmail.com>
Diffstat (limited to 'services')
-rw-r--r--services/monitoring/wrapper.nix15
1 files changed, 15 insertions, 0 deletions
diff --git a/services/monitoring/wrapper.nix b/services/monitoring/wrapper.nix
new file mode 100644
index 0000000..416ae22
--- /dev/null
+++ b/services/monitoring/wrapper.nix
@@ -0,0 +1,15 @@
+# This wraps the monitoring service module to allow it to be
+# imported conditionally.
+{ lib, pkgs, auxiliaryPkgs, config, ... }:
+
+let
+  enabled = config.foundation.internal.monitoringService;
+  module = import ./.;
+in
+{
+  options.foundation.internal = {
+    monitoringService = lib.mkEnableOption "monitoring service";
+  };
+
+  config = lib.mkIf enabled (module { inherit lib pkgs auxiliaryPkgs; });
+}