nginx中不设定或者不检查 header last-modified

搜索 nginx header unset last-modified 找到了答案

Igor Sysoev
Re: How to disable/not to send Last-Modified Header
March 11, 2010 04:04PM Admin
Registered: 1 year ago
Posts: 2,277
On Thu, Mar 11, 2010 at 12:08:43PM -0500, tunggad wrote:

We are using NGINX to front end Jetty Server, serving static content is done by NGINX and we want to disable/remove the Last-Modified Header.

nginx infinit redirect problem

Igor Sysoev to nginx
show details 4:04 AM (4 hours ago)
On Mon, Aug 02, 2010 at 10:01:26PM +0200, Fernando Perez wrote:

Sorry for the typos, trialing should read trailing.

Here is the complete thing for those interested, your mileage may vary
depending how you want the backend app to handle /blog/uri or just /uri

location ^~ /blog/ {
rewrite /blog/(.+) $1 break;
proxy_set_header Host $http_host;
root /optional/root;
proxy_pass http://127.0.0.1:3000/$1;
}

nginx 下如何缓存有cookie的请求

参考: http://forum.nginx.org/read.php?2,105524,106854#msg-106854

Igor Sysoev Wrote:

*) Change: now nginx does not cache by default
backend responses, if
they have a "Set-Cookie" header line.

What's the recommended method to cache even with the Set-Cookie header
present?

proxy_ignore_headers Set-Cookie;
proxy_hide_header Set-Cookie;

Note that Set-Cookie header no longer hidden by default so you
have to explicitly hide it via proxy_hide_header if it's not

现在我如何启动php-fastcig

现在使用的方法

这个方法不好,参考 http://pengyou.rijiben.org/node/3185

之前的方法

参考: http://www.cyberciti.biz/faq/freebsd-configure-nginx-php-fas...

然后在本机安装一个lighttpd,把 /usr/local/bin/spawn-fcgi 复制到服务器一个目录下。这个文件是lightttpd带的,用来启动fastcgi的。

在服务器上写一个脚本,一句话: /home/apache/apps/spawn-fcgi -a 127.0.0.1 -p 3456 -u apache -g apache -f /home/apache/apps/fastcgiphp/bin/php-cgi 可以把这句话加到 /etc/rc.local 让它开机启动