[exim] Exim 3.36, mySQL and route_list

Página Inicial
Delete this message
Reply to this message
Autor: Rob Stead
Data:  
Para: exim-users
Assunto: [exim] Exim 3.36, mySQL and route_list

Hello. Newbie first question.

I would like to relay a domain to specified smarthosts. eg

example1.com to mx1.anotherdomain.com
example2.com to mx2.anotherdomain.com

This works fine using a file and this config line:

route_list = "* ${extract{smart_host}{${lookup{$domain}lsearch \
      {/etc/exim/smtp_users}{$value}fail}}} bydns_a"


but if I try to use mySQL it fails.

The condition in the example below works but route_list doesn't.

smarthost_tg:
condition = ${lookup mysql{MYSQL_RELAY_DOMAINS}{$value}fail}
driver = domainlist
transport = remote_smtp
route_list = * ${lookup mysql {MYSQL_SMARTHOST}{$value}fail} bydns_a

MYSQL_SMARTHOST represents a SQL statement that returns the smarthost for
the domain in question.

Can someone help me with the correct syntax or point me in the right
direction?

Thanks in advance.

Rob

---------------------------------------------------------------
Rob Stead