[exim] redirect driver + transport choice

Top Page
Delete this message
Reply to this message
Author: Marcin Gryszkalis
Date:  
To: exim users
Subject: [exim] redirect driver + transport choice
Hi
As specification says "The generic transport option must not be set for
redirect router" but I sitll wanted to choose transport:

I have database with users and 2 fields - CC and SMS, both fields specify list
of addresses to copy message to - the difference is that message should be
filtered by external filter (in transport) before sending to SMS address (the
filter removes attachements, html etc.)

dnslookup:
    driver = dnslookup
    domains = ! +local_domains
    transport = ${if eq{$address_data}{SMS}{remote_smtp_sms}{remote_smtp}}
    ignore_target_hosts = 0.0.0.0 : 127.0.0.0/8
    no_more



mysql_cc:
      driver = redirect
    data = ${lookup mysql {SELECT cc FROM user WHERE 
        username='${quote_mysql:$local_part}' 
        AND domain='${quote_mysql:$domain}'}{$value}}
      unseen


mysql_sms:
    driver = redirect
    data = ${lookup mysql {SELECT sms FROM user WHERE 
        username='${quote_mysql:$local_part}' 
        AND domain='${quote_mysql:$domain}'}{$value}}
    headers_add = X-SMS-Gateway-Filter: Yes
      address_data = SMS
      unseen



but it seems that $address_data is not good choice for generic variable to
store such information. For unknown reasons sometimes redirection via CC
field goes through remote_smtp_sms transport.

I tried to check for header:

transport =
${if eq{$header_X-SMS-Gateway-Filter:}{Yes}{remote_smtp_sms}{remote_smtp}}

but it doesn't work...


How these redirections could be configured?

best regards
--
Marcin Gryszkalis, PGP 0x9F183FA3
jabber jid:mg@???, gg:2532994
http://the.fork.pl