atom feed9 messages in net.sourceforge.lists.courier-imapRe: [Courier-imap] $(server_port) and...
FromSent OnAttachments
Mike CardwellAug 3, 2006 10:23 am 
Brian CandlerAug 3, 2006 1:29 pm 
Michael BoweAug 3, 2006 2:49 pm 
Mike CardwellAug 4, 2006 2:00 am 
Brian CandlerAug 5, 2006 1:04 am 
Mike CardwellAug 15, 2006 3:17 am 
Mark MoseleyAug 22, 2006 4:04 pm 
Mike CardwellAug 22, 2006 4:35 pm 
Mike CardwellAug 23, 2006 4:58 am 
Subject:Re: [Courier-imap] $(server_port) and/or $(server_addr) request
From:Mike Cardwell (cour@lists.mrthearchitect.com)
Date:Aug 23, 2006 4:58:42 am
List:net.sourceforge.lists.courier-imap

* on the Wed, Aug 23, 2006 at 12:35:53AM +0100, Mike Cardwell wrote:

You can get something akin to $(server_port) by using AUTHSERVICE* strings in your imapd config file (though I don't have a clue if this was offered in 3.x). You'd have something like this in "imapd": AUTHSERVICE14301=arbitrarystring1 (or perhaps just =14301) AUTHSERVICE14302=arbitrarystring2 AUTHSERVICE14303=arbitrarystring3 etc

Perfect! I was looking into sticking perdition in front of courier to handle this, but now I don't have to. Thank you for taking the time to respond Mark. I have already upgraded to v4 so the features should be available to me. I'll look into it at work tomorrow.

Works like a charm. Added the following to authmysqlrc:

DEFAULT_DOMAIN garbage-default-domain

In the MySQL query, if $(domain) is "garbage-default-domain" then it uses the one from the appropriate table in the db instead, eg:

AND mail.domain = IF( '$(domain)' = 'garbage-default-domain', supplier.default_domain, '$(domain)' )

In my imapd config I have:

PORT=14301,14302,14303,14304 AUTHSERVICE14301=14301 AUTHSERVICE14302=14302 AUTHSERVICE14303=14303 AUTHSERVICE14304=14304

It's a shame that the $(server_port) functionality doesn't exist, but I guess I'd need to update the config file and restart to add more ports anyway as we get more "suppliers".

Mike