[exim] question of string expansion and condition=

Top Page
Delete this message
Reply to this message
Author: Robert Bannocks
Date:  
To: exim-users@exim.org
Subject: [exim] question of string expansion and condition=
Hi

I am trying to have a look up dependent on the $primary_hostname in a file via the condition restriction on a router.

What I want is that if the $primary_hostname is in the file with no further information then defaults apply, else if there is some information then that will be used.

But the router will not run if the look up returns a blank if we have a file like

exim-box1.localdomain:
exim-box2:localdomain: data...data

My condition is

FILENAME=/abc/def
Condition = ${lookup{$primary_hostname}lsearch{FILENAME}}

For exim-box1.localdomain the router does not run. It does for exim-box2.localdomain. Trying ${if has lead to no joy. Can you please assist?
This email and any attachments are intended solely for the addressee and may contain confidential information. If you are not the intended recipient of this email and/or its attachments you must not take any action based upon them and you must not copy or show them to anyone. Please send the email back to us and immediately and permanently delete it and its attachments. Where this email is unrelated to the business of University of the Arts London or of any of its group companies the opinions expressed in it are the opinions of the sender and do not necessarily constitute those of University of the Arts London (or the relevant group company). Where the sender's signature indicates that the email is sent on behalf of UAL Short Courses Limited the following also applies: UAL Short Courses Limited is a company registered in England and Wales under company number 02361261. Registered Office: University of the Arts London, 272 High Holborn, London WC1V 7EY