summaryrefslogtreecommitdiff
path: root/hosts/surtr/email/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'hosts/surtr/email/default.nix')
-rw-r--r--hosts/surtr/email/default.nix4
1 files changed, 2 insertions, 2 deletions
diff --git a/hosts/surtr/email/default.nix b/hosts/surtr/email/default.nix
index 0ee68599..fa939252 100644
--- a/hosts/surtr/email/default.nix
+++ b/hosts/surtr/email/default.nix
@@ -200,7 +200,7 @@ in {
200 virtual_mailbox_maps = ''pgsql:${pkgs.writeText "virtual_mailbox_maps.cf" '' 200 virtual_mailbox_maps = ''pgsql:${pkgs.writeText "virtual_mailbox_maps.cf" ''
201 hosts = postgresql:///email 201 hosts = postgresql:///email
202 dbname = email 202 dbname = email
203 query = SELECT 1 FROM virtual_mailbox_mapping WHERE lookup = '%s' 203 query = SELECT 1 FROM virtual_mailbox_mapping WHERE lookup = '%s' OR (lookup = regexp_replace('%s', '\+[^@]*@', '@') AND NOT EXISTS (SELECT 1 FROM virtual_mailbox_mapping WHERE lookup = '%s'))
204 ''}''; 204 ''}'';
205 dvlmtp_destination_recipient_limit = "1"; 205 dvlmtp_destination_recipient_limit = "1";
206 virtual_transport = "dvlmtp:unix:/run/postfix/dovecot-lmtp"; 206 virtual_transport = "dvlmtp:unix:/run/postfix/dovecot-lmtp";
@@ -239,7 +239,7 @@ in {
239 "-o" ''{smtpd_recipient_restrictions=reject_unauth_pipelining,reject_non_fqdn_recipient,reject_unknown_recipient_domain,check_recipient_access pgsql:${pkgs.writeText "check_recipient_access.cf" '' 239 "-o" ''{smtpd_recipient_restrictions=reject_unauth_pipelining,reject_non_fqdn_recipient,reject_unknown_recipient_domain,check_recipient_access pgsql:${pkgs.writeText "check_recipient_access.cf" ''
240 hosts = postgresql:///email 240 hosts = postgresql:///email
241 dbname = email 241 dbname = email
242 query = SELECT action FROM virtual_mailbox_access WHERE lookup = '%s' 242 query = SELECT action FROM virtual_mailbox_access WHERE lookup = '%s' OR (lookup = regexp_replace('%s', '\+[^@]*@', '@') AND NOT EXISTS (SELECT 1 FROM virtual_mailbox_access WHERE lookup = '%s'))
243 ''},permit_tls_all_clientcerts,reject}'' 243 ''},permit_tls_all_clientcerts,reject}''
244 "-o" "milter_macro_daemon_name=surtr.yggdrasil.li" 244 "-o" "milter_macro_daemon_name=surtr.yggdrasil.li"
245 "-o" ''smtpd_milters=${config.services.opendkim.socket}'' 245 "-o" ''smtpd_milters=${config.services.opendkim.socket}''