From 544c9b81b492a32769b4c7d2c194f94dddff2825 Mon Sep 17 00:00:00 2001 From: Thary Date: Tue, 16 Sep 2025 17:11:03 +0300 Subject: [PATCH] refactor(email-options): rename selfprivacy.email.subdomain to domain --- selfprivacy-module.nix | 8 ++++---- sp-modules/simple-nixos-mailserver/config.nix | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/selfprivacy-module.nix b/selfprivacy-module.nix index 51d45e5..3c6dd68 100644 --- a/selfprivacy-module.nix +++ b/selfprivacy-module.nix @@ -193,13 +193,13 @@ with lib; email = with lib; mkOption { type = types.attrsOf ( types.submodule ( - { name, ... }: { + { ... }: { options = { - subdomain = mkOption { + domain = mkOption { type = with types; strMatching "[A-Za-z0-9][A-Za-z0-9\-]{0,61}[A-Za-z0-9]"; - example = "myservice"; + example = "myservice.example.net"; default = config.sp.domain; - description = "Email subdomain"; + description = "Domain to send emails from"; }; systemdTargets = mkOption { diff --git a/sp-modules/simple-nixos-mailserver/config.nix b/sp-modules/simple-nixos-mailserver/config.nix index 9bb7122..7425ea9 100644 --- a/sp-modules/simple-nixos-mailserver/config.nix +++ b/sp-modules/simple-nixos-mailserver/config.nix @@ -23,7 +23,7 @@ let inherit (value) hashedPasswordFile sendOnly; } ) sp.email; - extraDomains = lib.mapAttrsToList (_: value: value.subdomain) sp.email; + extraDomains = lib.mapAttrsToList (_: value: value.domain) sp.email; extraTargets = lib.mapAttrsToList (_: value: value.systemdTargets) sp.email; in lib.mkIf sp.modules.simple-nixos-mailserver.enable (