On Mon, Jul 23, 2012 at 07:27:05PM -0400, Wietse Venema wrote:
> Marty Beckler:
> > Transport next hops can have MX lookups disabled by adding [] around
> > the next hop.
> >
> > Is it possible to define a transport that always has MX lookups
> > disabled without specifying the next hop?
>
> /etc/postfix/transport:
> example.com smtp-no-mx:
>
> /etc/postfix/master.cf:
> smtp-no-mx unix - - n - - smtp
> disable_dns_lookups=yes
That should of course have a "-o" flag:
/etc/postfix/master.cf:
smtp-no-mx unix - - n - - smtp
-o disable_dns_lookups=yes
This is generally a bad idea, non-mx destinations should be the
exception, not the rule. Since you're not likely to set
default_transport = smtp-no-mx
destinations that use it would be explicitly listed in the transport
table, and it is no harder to type:
example.com smtp:[gateway.example.com]
than:
example.com smtp-no-mx:gateway.example.com
Avoid "disable_dns_lookups=yes" it is more likely to be misused than
used correctly.
--
Viktor.