Re: [Exim] lookup question

Página superior
Eliminar este mensaje
Responder a este mensaje
Autor: Kelley Reynolds
Fecha:  
A: Tony Finch
Cc: exim-users
Asunto: Re: [Exim] lookup question
My fault, let me be more explicit.

If the command is specified as

command = /bin/sh "${lookup pgsql{select homedir from domains where domain='$domain' limit 1} {$value} mail}/mailman/mail/mailman"

then it works fine since the pipe command breaks it up according to whitespace. Now, if I replace /bin/sh with a single-quoted lookup that doesn't itself contain any single quotes, then there is no problem. For example

command = '${lookup pgsql{select homedir from domains where 3=3 limit 1} {$value} mail}/mailman/mail/mailman'

Unfortunately, for a text lookup to occur in pgsql, it has to be surrounded by single quotes (tried double quotes, and pgsql threw an error). So, the following *should* work, but doesn't.

command = "${lookup pgsql{select homedir from domains where domain='$domain' limit 1} {$value} mail}/mailman/mail/mailman"

According to 28.2, things inside double-quotes are escaped, but just to check I escaped the single quotes and still it gave the error of "missing lookup type"

Is there something eluding me, or are the double-quotes not being used properly for the 'command' portion of pipe as opposed to the 'argument' portion?

Kelley