On Jan 8, 2011, at 5:43 AM, jeff wrote:
> 
> And I have obviously to write some lines in routes.py like (the proxy
> action is in the w.py controller of the poc app):
> 
> (r'.*:http://.*:.* /(?P<any>(?:admin/|poc/).*)',
> r'/\g<any>'),
> (r'.*:http://.*:.* /(?P<any>.*)',
> r'/poc/w/proxy/vars=\g<any>'), # I think that's not used
> 
> That seems do the job (and it's quite faaaaaaaast ;-)  ).  I can even
> crawl the old website and it will stand entirely in the cache, I would
> then be able to shut down the php server (providing I manage the 4xx
> errors myself)

I may be reading this wrong, but you may find that your vars= line might cause 
problems. 

If you really want a 'vars=something' construct, you need something like this:

(r'/(?P<any>.*)', r'/poc/w/proxy?vars=\g<any>')

...but that is likely to mess up some of your incoming URLs (I don't know what 
they look like; maybe not).

or this: 

(r'/(?P<any>.*)', r'/poc/w/proxy/\g<any>')

...where you'll find the proxied path in request.args and also request.vars if 
there's a query string.

Reply via email to