From 1df959136d08aab5d8aa515ed2da051a2fba6b04 Mon Sep 17 00:00:00 2001 From: h7x4 Date: Sat, 11 May 2024 20:25:45 +0200 Subject: [PATCH] modules: add sendonly postfix modules --- modules/sendonly-postfix.nix | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 modules/sendonly-postfix.nix diff --git a/modules/sendonly-postfix.nix b/modules/sendonly-postfix.nix new file mode 100644 index 0000000..4393d72 --- /dev/null +++ b/modules/sendonly-postfix.nix @@ -0,0 +1,23 @@ +{ config, pkgs, lib, ... }: +let + cfg = config.services.postfix; +in +{ + services.postfix = { + enable = true; + + hostname = "${config.networking.hostName}.pvv.ntnu.no"; + domain = "pvv.ntnu.no"; + + relayHost = "smtp.pvv.ntnu.no"; + relayPort = 465; + + config = { + smtp_tls_wrappermode = "yes"; + smtp_tls_security_level = "encrypt"; + }; + + # Nothing should be delivered to this machine + destination = [ ]; + }; +}