dovecot director redirect some user to always same backend

Timo Sirainen tss at iki.fi
Fri Jan 22 11:51:08 UTC 2016


> On 21 Jan 2016, at 16:04, Tobi <tobster at brain-force.ch> wrote:
> 
> Hello list
> 
> I have a question on how to enforce certain user(s) always to the same
> backend in a dovecot setup with director.
> So I changed my passdb-mysql query
> 
> SELECT password AS password, username AS destuser, 'Y' as proxy,
> (CASE username WHEN LIKE 'user' THEN '10.66.99.6' ELSE null END)
> as host from mailbox WHERE username = '%u' AND active = 1;
> 
> But then I saw in the dovecot manual that the director does nothing if
> the passdb query already returns a host field.
> So I'm quite unsure whether a host field with value NULL means that the
> host field is not present and therefore the director should insert it
> into the result or not.

NULL as host doesn't actually return the host field. So the above should work.



More information about the dovecot mailing list