<div dir="ltr"><div><div><div>Hello Maxim,<br><br></div>Would you suggest the code change to achieve this?<br><br></div>Thanks,<br></div>Makailol<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Jan 20, 2014 at 7:18 PM, Maxim Dounin <span dir="ltr"><<a href="mailto:mdounin@mdounin.ru" target="_blank">mdounin@mdounin.ru</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello!<br>
<div class="im"><br>
On Mon, Jan 20, 2014 at 09:40:30PM +0800, Rv Rv wrote:<br>
<br>
> Hello<br>
> Is there a way we can achieve the following when nginx is acting<br>
> as a reverse proxy<br>
</div>> 1. Client sends HTTP request with Accept-Encoding as gzip<br>
> 2. Nginx proxy forwards the request with the request<br>
> header intact<br>
> 3. Origin server sends a compressed response<br>
> 4. At the nginx proxy, we *decompress* the response, apply<br>
<div class="im">> transformations on the response body and then *again*<br>
> compress it<br>
> In other words, is there a way to use the functionality of gzip<br>
> and gunzip modules simultaneously for a processing a response<br>
> and in a particular order<br>
<br>
</div>As of now, it's not possible without code modifications - mostly<br>
because there is no way to tell gunzip filter you want it to<br>
always decompress a response. It can be achieved with minor code<br>
changes though.<br>
<span class="HOEnZb"><font color="#888888"><br>
--<br>
Maxim Dounin<br>
<a href="http://nginx.org/" target="_blank">http://nginx.org/</a><br>
<br>
_______________________________________________<br>
nginx mailing list<br>
<a href="mailto:nginx@nginx.org">nginx@nginx.org</a><br>
<a href="http://mailman.nginx.org/mailman/listinfo/nginx" target="_blank">http://mailman.nginx.org/mailman/listinfo/nginx</a><br>
</font></span></blockquote></div><br></div>