From c4a780b7ff92e6403fbf60781ec695a7f7123920 Mon Sep 17 00:00:00 2001 From: Thary Date: Sat, 13 Sep 2025 11:34:54 +0300 Subject: [PATCH] fix --- module.nix | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/module.nix b/module.nix index 5633b64..44910ec 100644 --- a/module.nix +++ b/module.nix @@ -95,17 +95,17 @@ in }; }; - # services.postfix.config = { - # smtp_sasl_auth_enable = "yes"; - # smtp_sasl_security_options = ""; - # smtp_sasl_password_maps = "texthash:/run/postfix/mastodon.cf"; - # virtual_mailbox_maps = [ "hash:/run/postfix/mastodon.cf" ]; - # }; - # mailserver.loginAccounts."noreply.mastodon@${sp.domain}" = { - mailserver.loginAccounts."mastodon@${sp.domain}" = { - hashedPasswordFile = "/run/postfix/mastodon.cf"; - sendOnly = true; + services.postfix.config = { + smtp_sasl_auth_enable = "yes"; + smtp_sasl_security_options = ""; + smtp_sasl_password_maps = "texthash:/run/postfix/mastodon.cf"; + virtual_mailbox_maps = [ "hash:/run/postfix/mastodon.cf" ]; }; + # mailserver.loginAccounts."noreply.mastodon@${sp.domain}" = { + # mailserver.loginAccounts."mastodon@${sp.domain}" = { + # hashedPasswordFile = "/run/postfix/mastodon.cf"; + # sendOnly = true; + # }; systemd = { services.mastodon-email-password-setup = { @@ -125,8 +125,8 @@ in rm -f /run/postfix/mastodon.cf || true mkdir /run/postfix/ || true # Create /run/postfix if it doesn't exist export hashedPassword=$(${lib.getExe pkgs.mkpasswd} -sm bcrypt "$password") - # echo "noreply.mastodon@${sp.domain}: $hashedPassword" > /run/postfix/mastodon.cf - echo "$hashedPassword" > /run/postfix/mastodon.cf + echo "noreply.mastodon@${sp.domain}:$hashedPassword" > /run/postfix/mastodon.cf + # echo "$hashedPassword" > /run/postfix/mastodon.cf chmod 440 /run/postfix/mastodon.cf chown ${config.services.postfix.user}:${config.services.postfix.group} /run/postfix/mastodon.cf '';