Quoting wie...@porcupine.org:
Per olof Ljungmark:
Quoting wie...@porcupine.org:
> Per olof Ljungmark:
>> Hi all,
>>
>> Hopefully I can explain this good enough for someone to understand and
>> perhaps even suggest a solution.
>>
>> Our email system is built from a LDAP directory that contains all the
>> necessary information about our users. A box receives mail from the MX's
>> and routes it according to the information in the directory.
>>
>> If the mail is for a user present in the directory it gets delivered to
>> the mail server, if it is for an external address it is delivered to the
>> outgoing box etc., everything dandy.
>>
>> Now we face a setup where we have users present in the same tree as our
>> normal mail users, but with addresses external to us. They must have the
>> "mail" attribute that we normally use for delivery to our mail server.
>> We cannot separate them to a different tree because it is actually a mix
>> of internal and external users for a different purpose than mail routing.
>
> Use a transport map.
>
> internalu...@example.com -> internal delivery agent or internal host
> externalu...@example.com -> external host
>
> http://www.postfix.org/postconf.5.html#transport_maps
> http://www.postfix.org/transport.5.html
>
> Wietse
Yes, but the problem seems to be that the address is rewritten to
uid@mail.server before the transport maps comes into play.
If mail.server is the "wrong" server (i.e. the name of an internal
server for users that deliver elsewhere) then that is the problem.
The transport map solution is for the case that the address is not
mutilated.
Indeed. Will start tomorrow to sketch a rework of the system so that
the rewrite is done where it should.
Thank you both for your input.
//per