Re: [Exim] Variables in the .include

Top Page
Delete this message
Reply to this message
Author: Philip Hazel
Date:  
To: mwalkup
CC: exim-users
Subject: Re: [Exim] Variables in the .include
On Fri, 21 Nov 2003 mwalkup@??? wrote:

> This, may seem like a strange question, but is there any way to use an
> environment variable in a .include?
>
> ie: .include \\\"/etc/exim/$HOSTNAME.conf\\\" ?


Using environment variables in any way in Exim is a security risk. So it
is not possible.

What's with all those backslashes? You don't need them.

> Im using CVS, and this would allow me to save all the configs to the
> CVS (as different files), and just have my exim.conf include the
> hostname configuration it needs.
>
> My example fails btw, and also:
>
> .include \\\"/etc/exim/${primary_hostname}.conf\\\"
>
> fails. I was thinking that because primary_hostname wasnt set it, it
> would use the uname.


The argument of .include is not string-expanded.



--
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.
Get the Exim 4 book:    http://www.uit.co.uk/exim-book