On Fri, Sep 25, 2020 at 05:16:26PM +0200, Hans van Zijst wrote:

> I might have been a little quick to react. Explicitly setting it to
> empty actually makes it an empty value :)

Correct.  More specifically it ensures that no domains are in the
"local" address class.  See ADDRESS_CLASS_README.

> What $mydestination means is what domains the machine should accept mail
> for as its final destination.

Final destinations include and

    - Local domains (listed in $mydestination)
    - Virtual mailbox domains (listed in $virtual_mailbox_domains)
    - Virtual alias domains (listed in $virtual_alias_domains), but
      for these, the address has to then actually rewrite to some
      "real" domain.

Additionally, Postfix will by default also accept inbound email to
domains in the "relay address class, which are then (unsurprisingly)
relayed (ideally closer) to their final destination.

> Explicitly setting it empty would ensure that no mail whatsoever is
> ever considered to be local, what would mean that it ends up in a
> local mailstore. Where it will probably be unnoticed forever...

It largely disables delivery to local accounts listed in /etc/passwd,
and in the local aliases(5) (but not virtual(5) aliases) table.
Delivery to virtual mailbox domains, and virtual alias domains is not
affected, nor is forwarding to any relay domains dependent on a non-
empty $mydestination.

> Your predecessor probably did this to make absolutely sure that that
> would never happen, and that every message had to be passed on to the
> central relaying server.

It ensures that mail to local user accounts is forwarded to the
relayhost for processing.

-- 
    Viktor.

Reply via email to