Welcome! Log In Create A New Profile

Advanced

Re: trying to get something like proxypassreverse going.

Francis Daly
August 21, 2010 11:02PM
Tim Uckun <timuckun@gmail.com> wrote:

Hi there,

>> Arrange that the backend application generates the correct-for-you urls
>> directly. That way, nginx doesn't have to do any special processing of
>> the body content, and it can just do what it does best.
>
> Thanks Francis for that concise and extremely clear explanation of
> what is going on. I now know where to go proceed.

You're welcome.

There's a fuller discussion of the issue -- in the context of apache --
at http://www.apachetutor.org/admin/reverseproxies#d8

If you really really can't adjust the backend application, then you'll
want something like apache's mod_proxy_html (or mod_substitute, or
mod_sed, but they will leave lots of the fiddly details up to you to
get right).

nginx_substitutions_filter at http://wiki.nginx.org/NginxHttpSubsModule
looks like the closest starting point to me; but you pretty much have to
parse the html and css to find things that end browser will consider a
url, and change all of them and only them. Parsing with regexes isn't fun.

Possibly someone has already done the work of creating an nginx version
of mod_proxy_html and then put it somewhere hidden from $SEARCH_ENGINE;
more likely everyone just configures the backend application to avoid
the need to adjust.

All the best,

f
--
Francis Daly francis@daoine.org

_______________________________________________
nginx mailing list
nginx@nginx.org
http://nginx.org/mailman/listinfo/nginx
Subject Author Posted

trying to get something like proxypassreverse going.

Tim Uckun August 19, 2010 05:02AM

Re: trying to get something like proxypassreverse going.

timuckun August 21, 2010 02:45AM

Re: trying to get something like proxypassreverse going.

Francis Daly August 21, 2010 11:48AM

Re: trying to get something like proxypassreverse going.

timuckun August 21, 2010 09:00PM

Re: trying to get something like proxypassreverse going.

Francis Daly August 21, 2010 11:02PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 193
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready