Re: Local validator via proxy

On Mon, 2004-10-18 at 13:49, Francesco Siviero ARPA-SIM wrote:

> Thanks for answering.
> After some trouble I've found that the SetEnv directive needs the 
> mod_env loaded (I'm quite a newbie, so maybe I could be worng).

Yes.

> my $ua = new LWP::UserAgent;
> $ua->env_proxy();
> $ua->agent("W3C_Validator/$VERSION " . $ua->agent);

Correct.

> <IfModule mod_env.c>
>          SetEnv http_proxy http://myuser:mypassword@myproxy:myport/
> </IfModule>

Correct, but note that you also do have to have mod_env loaded,
otherwise the above has no effect.

> but I'm not sure to understand what you mean with
> "Then, add your proxy settings as environment variables to your web
> server config (somewhere so that they apply to the "check" script)"

It's not quite possible to give detailed instructions because it depends
so much on how your web server configuration is laid out, whether you
use virtual hosts etc.  All the necessary documentation should be "out
there", see http://httpd.apache.org/ (or the Debian docs, IIRC you said
you used it).

Another (uglier) thing you could try would be to hardcode the proxy
settings directly into the check script, for example something like
this, somewhere near the beginning of it:

  $ENV{http_proxy} = 'http://myuser:mypassword@myproxy:myport/;

Received on Monday, 18 October 2004 11:13:21 UTC