From cc88c367bbe0982d7f3f754b90c7a952658b52b2 Mon Sep 17 00:00:00 2001 From: Felix Buehler Date: Fri, 30 Aug 2024 00:47:06 +0200 Subject: [PATCH] nixos/services.uptime-kuma: remove `with lib;` --- .../modules/services/monitoring/uptime-kuma.nix | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/nixos/modules/services/monitoring/uptime-kuma.nix b/nixos/modules/services/monitoring/uptime-kuma.nix index 4c7dd900f52b..1d7ff10227a9 100644 --- a/nixos/modules/services/monitoring/uptime-kuma.nix +++ b/nixos/modules/services/monitoring/uptime-kuma.nix @@ -1,7 +1,4 @@ { config, pkgs, lib, ... }: - -with lib; - let cfg = config.services.uptime-kuma; in @@ -11,11 +8,11 @@ in options = { services.uptime-kuma = { - enable = mkEnableOption "Uptime Kuma, this assumes a reverse proxy to be set"; + enable = lib.mkEnableOption "Uptime Kuma, this assumes a reverse proxy to be set"; - package = mkPackageOption pkgs "uptime-kuma" { }; + package = lib.mkPackageOption pkgs "uptime-kuma" { }; - appriseSupport = mkEnableOption "apprise support for notifications"; + appriseSupport = lib.mkEnableOption "apprise support for notifications"; settings = lib.mkOption { type = lib.types.submodule { freeformType = with lib.types; attrsOf str; }; @@ -33,13 +30,13 @@ in }; }; - config = mkIf cfg.enable { + config = lib.mkIf cfg.enable { services.uptime-kuma.settings = { DATA_DIR = "/var/lib/uptime-kuma/"; - NODE_ENV = mkDefault "production"; - HOST = mkDefault "127.0.0.1"; - PORT = mkDefault "3001"; + NODE_ENV = lib.mkDefault "production"; + HOST = lib.mkDefault "127.0.0.1"; + PORT = lib.mkDefault "3001"; }; systemd.services.uptime-kuma = {