I have a problem with my sendmail config. Need to use a smart host, but local services that send mail to local accounts need to post local.
I use this lines
LOCAL_DOMAIN(`localhost.localdomain')dnl
LOCAL_DOMAIN(`acme.com')dnl
… and file /etc/mail/local-host-names
Any idea. Need more info?
According to what I can find around, the following macro directs sendmail to use the esmtp
mailer for "local" mail instead of sending it through the smart relay.
LOCAL_NET_CONFIG
R$* < @ $* .$m. > $* $#esmtp $@ $2.$m $: $1 < @ $2.$m. > $3
On my systems, these are the last two lines in the default sendmail.mc
, as shipped.
Depending on exactly how local your "local accounts" are, you may want to use $#local
in place of $#esmtp
, after suitable testing.