Closed rkearsley closed 11 years ago
On Tue, Jul 9, 2013 at 9:13 AM, Richard Kearsley notifications@github.comwrote:
Hi
My current solution to this is to duplicate locations :( and add 'gzip on;' to them and then ngx.exec accordingly
It would be nicer if I could do something like 'ngx.var.gzip = "on"'
I think the cheapest way to do something like that would be to modify the internal Nginx gzip module just a tiny bit to accept a variable input (evaluated at each request), instead of using a fixed toggle per location.
Hope this helps, Matthieu.
Yes, it's indeed the ngx_gzip module's duty to be more flexible here. There's not really anything that can be done on the ngx_lua side.
roger that thanks
Hi
My current solution to this is to duplicate locations :( and add 'gzip on;' to them and then ngx.exec accordingly
It would be nicer if I could do something like 'ngx.var.gzip = "on"'
Is there another way?
Many thanks