Some time ago, it was mentioned that we can not limit the traffic per
server on Nginx. We have to use traffic shaper at the OS level to do
that. Is it still the case now?
And I want to try Nginx, but I can not find any where in the
documentations about how to do the HTTP header re-write. What I would
like to do is to be able to re-write the HTTP header set by Drupal,
especially the “Expires”, “Cache-Control”, “Last-Modified”,
“Content-Encoding” and “Content-Type” headers. I am using Lighttpd and I
can do the removal and re-write of those HTTP headers via mod_magnet LUA
script. Is there similar function like that in Cherokee, which allow me
to do that without changing anything in Drupal?
As for the http header rewrite, it depends on your needs. In simple
cases,
you can use “proxy_hide_header” and “add_header” directive to hide some
headers from upstream response and add them back using variables
supported
by Nginx. This is more or less the same as “http header rewrite”.
However, if your “rewrite” needs include conditional logic, I just don’t
know how to do that.
I do need conditional logic, especially to re-write the “Content-Type”
header. So I can set it depending on whether the original file is *.js,
*.css or *.html when serving their gzip format. As I said before, I can
easily do that using Lighttpd via mod_magnet LUA script. So I am
wondering if I could do that in Nginx when I finally use it to replace
my Lighttpd (if it really could replace it).
I do need conditional logic, especially to re-write the “Content-Type” header. So I can set it depending on whether the original file is *.js, *.css or *.html when serving their gzip format.
No. I have not tried that module. Mainly because the Limitation section says
as below, which means it can not handle Expires, Cache-Control, and
Last-Modified headers. And it suggests to do that via the Headers module
which can not do any re-write.
Have you tried it together with the standard headers module?
No. I have not tried that module. Mainly because the Limitation section
says as below, which means it can not handle Expires, Cache-Control, and
Last-Modified headers. And it suggests to do that via the Headers module
which can not do any re-write.
“Limitations
Unlike the standard headers module, this module does not automatically
take care of the constraint among the Expires, Cache-Control, and
Last-Modified headers. You have to get them right yourself or use the
headers module together with this module.”
No. I have not tried that module. Mainly because the Limitation section
says as below, which means it can not handle Expires, Cache-Control, and
Last-Modified headers. And it suggests to do that via the Headers module
which can not do any re-write.
“Limitations
Unlike the standard headers module, this module does not automatically
take care of the constraint among the Expires, Cache-Control, and
Last-Modified headers. You have to get them right yourself or use the
headers module together with this module.”
No, I have not tried that together. As I still can not debianized
Nginx 0.8.x core, so adding HttpHeadersMore module would be more
problematic for me. Is there any full debian package of Nginx 0.8.x
including the HttpHeadersMore module, especially for debian squeeze? Or
do you have any hint to debianized it?
I know that we can easily compile them together, but I want to have a
clean environment on my VPS. So I prefer to install it from a deb
package on my VPS.
Thanks in advance.
Anto
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.