From 3c8caa0a17df13b9aaf85c0c4639e905f76c1f44 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Leonardo=20Eug=C3=AAnio?= Date: Fri, 3 May 2024 12:32:38 -0300 Subject: [PATCH 1/2] fixup! switch: don't show git diff pager --- switch-phantom | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/switch-phantom b/switch-phantom index c824b0c..0449f75 100755 --- a/switch-phantom +++ b/switch-phantom @@ -2,7 +2,7 @@ nix fmt -git diff +git --no-pager diff nixos-rebuild switch --flake .#phantom \ --update-input nixpkgs \ From 4f54c31dc548de33a612dd08130588fcfd1362ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Leonardo=20Eug=C3=AAnio?= Date: Fri, 3 May 2024 12:32:45 -0300 Subject: [PATCH 2/2] email: disable ipv6 smtp --- hosts/phantom/email.nix | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/hosts/phantom/email.nix b/hosts/phantom/email.nix index d56a946..e778de4 100644 --- a/hosts/phantom/email.nix +++ b/hosts/phantom/email.nix @@ -1,4 +1,4 @@ -{ pkgs, inputs, ... }: { +{ pkgs, inputs, config, ... }: { # It's important to let Digital Ocean set the hostname so we get rDNS to work networking.hostName = ""; @@ -27,13 +27,18 @@ }; }; + # Prefer ipv4 and use main ipv6 to avoid reverse DNS issues + services.postfix.extraConfig = '' + smtp_address_preference = ipv4 + ''; + # Webmail - services.roundcube = rec { + services.roundcube = { enable = true; package = pkgs.roundcube.withPlugins (p: [ p.carddav ]); hostName = "mail.lelgenio.xyz"; extraConfig = '' - $config['smtp_host'] = "tls://${hostName}:587"; + $config['smtp_host'] = "tls://${config.mailserver.fqdn}:587"; $config['smtp_user'] = "%u"; $config['smtp_pass'] = "%p"; $config['plugins'] = [ "carddav", "archive" ];