[exim] To unseen, or not unseen, that is the question....

Top Page
Delete this message
Reply to this message
Author: Ian P. Christian
Date:  
To: exim-users
Subject: [exim] To unseen, or not unseen, that is the question....
I've had this problem before, and the way I solved it last time I was
really unhappy with, so I though I'd ask the collective to see if anyone
can come up with something smart for me. I have this in my config:

mysql_virtual_forward:
driver = redirect
allow_defer
allow_fail
retry_use_local_part
data = ${lookup mysql {MYSQL_FORWARD}}

mysql_virtual_mailbox:
domains = ${lookup mysql {MYSQL_MAILBOX}{$value}}
driver = accept
retry_use_local_part
transport = dovecot_delivery

So, I have a database table containing mailboxes, and one for forwards.
This works fine, until you want an email address that forwards AND is a
mailbox. Mailboxes are in the form of an email address, so for example,
I have a 'ian@???' email address, and 'pookey@???'
forwards to it.

It will hit the first router, and go no futher. This is what 'unseen'
is for if I understand correctly. However, if I unseen the first
router, in cases where an email only matches the first router, and not
the second, it will appear as undeliverable, as it will not have hit any
'seen' routers.

With 'unseen' on the first router, I see this:

# exim -bt pookey@???
pookey@??? is undeliverable: Unrouteable address
    <-- pookey@???
ian@???
    <-- pookey@???
    <-- pookey@???
  router = mysql_virtual_mailbox, transport = dovecot_delivery


Where as, the expected behaviour (as can be observed with no unseen in
the first router) is:

# exim -bt pookey@???
ian@???
    <-- pookey@???
  router = mysql_virtual_mailbox, transport = dovecot_delivery



So, what I want is the best of both worlds. Any ideas?

Thanks