From 8ce3d42c13c3cc04aec72d8e4bc7f8d1b3d06349 Mon Sep 17 00:00:00 2001 From: Robin Raymond Date: Tue, 21 Nov 2017 11:52:16 +0100 Subject: [PATCH] implement extraVirtualAliases --- mail-server/postfix.nix | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/mail-server/postfix.nix b/mail-server/postfix.nix index c243f3a..121e225 100644 --- a/mail-server/postfix.nix +++ b/mail-server/postfix.nix @@ -30,11 +30,18 @@ let cfg.loginAccounts); # extra_valiases_postfix :: [ String ] - extra_valiases_postfix = map + # TODO: Remove virtualAliases when deprecated -> removed + extra_valiases_postfix = (map (from: let to = cfg.virtualAliases.${from}; in "${from} ${to}") - (builtins.attrNames cfg.virtualAliases); + (builtins.attrNames cfg.virtualAliases)) + ++ + (map + (from: + let to = cfg.extraVirtualAliases.${from}; + in "${from} ${to}") + (builtins.attrNames cfg.extraVirtualAliases)); # all_valiases_postfix :: [ String ] all_valiases_postfix = valiases_postfix ++ extra_valiases_postfix;