Hi,
i asked:
> I use it to "split across multiple backend servers on a per user
basis",
> that means i have a file popmap with lines that look like these:
>
> user1:pophost1:popport1
> user2:pophost2:popport2
[...]
> Is there a way to lookup in this popmap file for the host and port
> information?
and after some help from Harald Meland an Peter Radcliffe i found the
following solution:
#director for localhost:305
cyrus:
driver = localuser
transport = local_delivery_cyrus
condition = "${if \
and{ \
{eq \
{${extract{1} {:} {${lookup {$local_part} lsearch
{/usr/local/etc/popmap} {$value}}}}} \
{localhost} \
} \
{eq \
{${extract{2} {:} {${lookup {$local_part} lsearch
{/usr/local/etc/popmap} {$value}}}}} \
{305} \
} \
} \
{yes} \
}"
The not easy to find part:
use no if before the eq expansion condition
Again thank you for your help,
Jochen
--
Sent through Global Message Exchange -
http://www.gmx.net