Welcome! Log In Create A New Profile

Advanced

nginx не кеширует

March 20, 2012 05:46AM
Добрый день,
тестирую кеширование перед вводом в production.
Конфигурация следующая:

#[http]
proxy_cache_path /var/cache/nginx levels=2:2 keys_zone=default:512m;

#[location]
location /test.php {
root /var/www/somesite/www;
proxy_pass http://127.0.0.1:8080;
proxy_cache default;
proxy_cache_valid 200 302 304 10m;
proxy_cache_valid 404 1m;
proxy_set_header If-Modified-Since "";
proxy_set_header If-None-Match "";
proxy_hide_header "Set-Cookie";
proxy_ignore_headers "Cache-Control" "Expires";
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
add_header X-test kukareku;
}

test.php:
<?php
print date('H:i:s');
?>


в location попадаю (проверил по добавленному заголовку) а вот кешировать не хочет
все запросы пролетают на backend
подскажите пожалуйста что я делаю не так?
Subject Author Posted

nginx не кеширует

neomag March 20, 2012 05:46AM

Re: nginx не кеширует

Маркел Мохначевский March 20, 2012 05:58AM

Re: nginx не кеширует

neomag March 20, 2012 06:48AM

Re: nginx не кеширует

Маркел Мохначевский March 20, 2012 07:32AM

Re: nginx не кеширует

Maxim Dounin March 20, 2012 08:28AM

Re: nginx не кеширует

neomag March 20, 2012 01:55PM

Re: nginx не кеширует

Maxim Dounin March 20, 2012 02:12PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 190
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready