Nginx-ru mailing list archive (nginx-ru@sysoev.ru)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: fastcgi cache valid для разных location'ов
- To: nginx-ru@xxxxxxxxx
- Subject: Re: fastcgi cache valid для разных location'ов
- From: "Namaste" <nginx-forum@xxxxxxxx>
- Date: Sat, 02 Mar 2013 03:58:00 -0500
- Dkim-signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tigger.jlkhosting.com; s=x; h=Date:Sender:From:References:In-Reply-To:Message-ID:Content-Transfer-Encoding:Content-Type:Subject:To; bh=9TgNi7D33AzHxaM4Xk+I9h9f0dyX36gflEpirsnsjbs=; b=WXMVDbEX6zw4/YxMLuI1gRQKx0B/MSu8W4Mxao/ufoAxd7GqSa2o0YwU/ag9f6UXUFcdUiNSRAnUdFc9FDNOm8Kt0L1Gd/XGZDRReBCJYdU88zYwlEw2scjKttpwZADf;
- In-reply-to: <174122756.20130302043446@mtu-net.ru>
- References: <174122756.20130302043446@mtu-net.ru>
В том то и дело, что так просто оно не работает.
например:
server {
fastcgi_cache_valid 200 301 302 10s;
location /aaa/ {
rewrite ^/aaa/([0-9]+)\.html$ /test.php?p1=$1 last;
}
location /bbb/ {
rewrite ^/bbb/([0-9]+)\.html$ /test2.php?p1=$1 last;
}
location ~ \.php$ {
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
fastcgi_cache mycache;
fastcgi_cache_key $scheme$host$request_uri$request_method;
#fastcgi_cache_valid 200 301 302 60m;
}
}
Так кэш вообще не включается.
Posted at Nginx Forum:
http://forum.nginx.org/read.php?21,236809,236814#msg-236814
_______________________________________________
nginx-ru mailing list
nginx-ru@xxxxxxxxx
http://mailman.nginx.org/mailman/listinfo/nginx-ru
|