相同的Postfix别名为不同的域

我有Postfixpipe理两个不同的域two.comtwo.com ,包含在main.cf文件的my destinationvariables中。

我需要一个/etc/aliases文件,包括像这样的东西:

 [email protected]: [email protected] [email protected]: [email protected] 

由于/etc/aliases语法不允许我这样做,我该如何解决?

你可以像这样使用virtual_alias_maps

 virtual_alias_maps = hash:/etc/postfix/virtualalias 

与这样的内容:

 [email protected] [email protected] [email protected] [email protected] 

当然,postfix需要知道如何处理地址。 之后,不要忘记postmap /etc/postfix/virtualalias并重新加载Postfix。

阅读http://www.postfix.org/VIRTUAL_README.html