[Pkg-exim4-users] (no subject)
Alex King
alex at king.net.nz
Tue Jan 10 19:40:09 UTC 2012
Hi Jon,
I think the answer is you don't do this in update-exim4.conf.conf
You need a new router as you have suggested below, and
update-exim4.conf.conf only selects preconfigured routers in the
standard configuration.
Are you using the split configuration, your config file below suggests
not? I would suggest this would be the way to go to achieve what you
want. You can read about it in
/usr/share/doc/exim4-config/README.Debian.gz. To select the split
configuration, edit update-exim4.conf.conf and change
dc_use_split_config to true, or run dpkg-reconfigure exim4-config and
select it there.
Once you have enabled the split configuration, create a file
/etc/exim4/conf.d/router/190_local_smarthost_alpha, and put your
smarthost_alpha router from below in it. 190 is selected so it comes
just before 200_exim4-config_primary, which has the preconfigured
smarthost router in it. You don't need your own smarthost router in
this case.
Then just reload exim4 and it should be working. You can check the
complete configuration file in /var/lib/exim4/config.autogenerated
Cheers,
Alex
On 11/01/12 06:22, Jon Seddon wrote:
> Hi,
>
> We have a mail system using exim4 on our ship. We currently send all emails to
> our ISP's mail server using the following lines in update-exim4.conf.conf:
>
> dc_eximconfig_configtype='smarthost'
> dc_other_hostnames=''
> dc_local_interfaces=''
> dc_readhost='ourdomain.co.uk'
> dc_relay_domains=''
> dc_minimaldns='true'
> dc_relay_nets='192.168.0.0/16'
> dc_smarthost='smtp.isp.com'
> CFILEMODE='644'
> dc_use_split_config='false'
> dc_hide_mailname='true'
> dc_mailname_in_oh='true'
> dc_localdelivery='mail_spool'
>
>
> We have a mixture of people onboard sending emails. Some work for our company
> and others work for other companies. Onshore our IT department operate the
> corporate email system. Some of our emails are being marked as spam and so we
> need to send emails that are coming from corporate addresses using the
> corporate mail server (which is now set up to relay emails from the vessel's IP
> address) but all other emails through the ISP's mail server.
>
> I believe that the following exim4 configuration would achieve this:
>
> smarthost_alpha:
> condition = ${if eq {${lc:$sender_address_domain}} {ourdomain.co.uk} {true}
> fail }
> driver = domainlist
> transport = remote_smtp
> route_list = "* smtp.ourdomain.co.uk bydns_a"
>
>
> smarthost:
> driver = domainlist
> transport = remote_smtp
> route_list = "* smtp.isp.com bydns_a"
>
> However, I am struggling to see how to implement this using the Debian
> configuration syntax in update-exim4.conf.conf. Any tips or pointers would be
> greatly appreciated!
>
>
> Thanks,
>
>
> Jon
>
>
>
> _______________________________________________
> Pkg-exim4-users mailing list
> Pkg-exim4-users at lists.alioth.debian.org
> http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-exim4-users
More information about the Pkg-exim4-users
mailing list