Is it possible to have infinite proxy_cache_valid?

Igor Sysoev igor at sysoev.ru
Mon Jul 12 19:59:57 MSD 2010


On Mon, Jul 12, 2010 at 02:53:55PM +0300, oren at stanzapub.com wrote:

>    Hi,
>    I want to be able to cache proxy responses indefinitely (until purged
>    manually by me, using cache purge module).
>    >From the docs it seems like proxy_cache_valid must get a number, can
>    it get something to tell it to store indefinitely (until purged or
>    until LRU)?
>    Something like:
>    proxy_cache_valid infinite;

Currently there is no way to say infinite, but you can set

     proxy_cache  /path/to/cache inactive=2y  ...;
     proxy_cache_valid  2y;


-- 
Igor Sysoev
http://sysoev.ru/en/



More information about the nginx mailing list