Re: [exim] Execute shell command on condition

Páxina inicial
Borrar esta mensaxe
Responder a esta mensaxe
Autor: John W. Baxter
Data:  
Para: exim-users
Asunto: Re: [exim] Execute shell command on condition
On 10/18/2004 3:42, "Fahd Korambayil" <fahd.korambayil@???> wrote:

> This is what I have so far and it works perfectly fine the way I want it to:
>
> drop message = No such user at domain.com
>       condition = ${lookup mysql{select username from usernames
> where username='$local_part'}{no}fail}

>
> However, I would like to do one additional thing; whenever the above
> condition returns true (that is the message is being rejected) I would
> like to execute the shell command "perl denyexim.pl
> $sender_host_address".


Take a look at the ${run ... } expansion. (Section 11.4 in the Exim 4.4
spec.)

Clearly, you would need to use a new-enough Exim version (whatever that is
for this expansion item).

--John