Author Login
Post Reply
Just an idea from a guy who really knows next to nothing about proxies :
If
- a proxy configuration allows you to selectively forward some requests
to a selection of sites, but not to a local file
- but what you want to do is to redirect some URLs to a local file
then can you not set up a local virtual host under some name, and
forward ditto "local" requests to that local virtual host, whose
pleasure it would be to serve the local stuff in question ?
André
Tavian Barnes wrote:
> On Tue, Jul 8, 2008 at 2:03 PM, Nick Kew <nick@(protected):
>> On Tue, 8 Jul 2008 13:48:54 -0600
>> "Tavian Barnes" <tavianator@(protected):
>>
>>> But that's a reverse proxy, not a forward one. I'm attempting to use
>>> an Apache server as a proxy for my web browser, that uses a local copy
>>> of certain files from certain sites. As such, it has to be a forward
>>> proxy, because I'm using it for arbitrary web sites.
>> That's not what you originally asked.
>
> It's what I attempted to ask, by referring to "forward proxies" in the
> subject line.
>
>> Anyway, three solutions, from the most sensible
>> to the least:
>> * Set up proxy exceptions in your browser preferences
>
> I know of nothing that can direct particular web addresses to local
> copies of files; all the tools I've seen can just selectively proxy
> addresses.
>
>> * Use mod_cache for your local copies
>
> My local copies are intended to differ from the copies on the web.
> Can mod_cache or mod_file_cache really be set to use a particular
> local version of a file, rather than automatically generating the
> cache? I realise that I didn't clarify this earlier.
>
>> * Use mod_rewrite - probably a rewritemap.
>
> Is there any reason I'd need to use a rewrite map? Reading through
> the mod_rewrite documentation, I came up with this,
>
> RewriteCond %{HTTP_HOST} ^www\.google\.com
> RewriteRule ^/ig /ig [R]
>
> which unfortunately doesn't work. What am I missing?
>
>> Unless of course your real purpose is to block crap like
>> animated images, in which case maybe the rewritemap makes
>> good sense (I use my ADSL router to do that).
>>
>> --
>> Nick Kew
>>
>> Application Development with Apache - the Apache Modules Book
>> http://www.apachetutor.org/
>>
>> ---------------------------------------------------------------------
>> The official User-To-User support forum of the Apache HTTP Server Project.
>> See <URL:http://httpd.apache.org/userslist.html> for more info.
>> To unsubscribe, e-mail: users-unsubscribe@(protected)
>> " from the digest: users-digest-unsubscribe@(protected)
>> For additional commands, e-mail: users-help@(protected)
>>
>>
>
>
>
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@(protected)
" from the digest: users-digest-unsubscribe@(protected)
For additional commands, e-mail: users-help@(protected)