Hi,
I need to take a copy of all mails sent to one domain to deliver to
another box inside my network, keeping the same local_part , but
changing the domain from barlibrary.com to umail.barlibrary.com.

I've tried this as the first router:

copy_temp:
  driver = redirect
  domains = barlibrary.com
  data = [EMAIL PROTECTED]
  unseen

But because of (I think) the following routers, the message gets set up
twice:

          
virtual_domains:
  driver = redirect
  allow_defer
  allow_fail
  data = ${expand:${lookup{$local_part}lsearch{/etc/exim/virtual/$domain}}}
  domains = dbm;/etc/exim/virtual/virtual-domains.db
  file_transport = address_file
  pipe_transport = address_pipe
  qualify_preserve_domain
  require_files = /etc/exim/virtual/$domain
  retry_use_local_part
  user = mail

virtual_domains_smart:
  driver = redirect
  allow_defer
  allow_fail
  data = ${lookup{*}lsearch{/etc/exim/virtual/$domain}{$value}fail}
  domains = dbm;/etc/exim/virtual/virtual-domains.db
  file_transport = address_file
  no_more
  require_files = /etc/exim/virtual/$domain
  retry_use_local_part
  user = mail

I also thought to try this in a system filter, but couldnt figure out
how to do so with $local_part not being available.

This is what happens with my current setup:

 exim -C test -bt [EMAIL PROTECTED]
[EMAIL PROTECTED] ->
/var/spool/virtual/barlibrary.com/pete.mcevoy
  transport = address_file
[EMAIL PROTECTED]
    <-- [EMAIL PROTECTED]
    <-- [EMAIL PROTECTED]
  router = lookuphost, transport = remote_smtp
  host umail.barlibrary.com [10.0.19.183]


Any pointers would be appreciated.

-- 
Pete

-- 
## List details at http://www.exim.org/mailman/listinfo/exim-users 
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://www.exim.org/eximwiki/

Reply via email to