如何配置我的VLC,让Varnish遵守'Cache-Control max-age‘请求头?
我注意到默认情况下,即使我在浏览器中按下F5 (因此请求一个‘新的’副本‘),varnish也会传递缓存的内容。
发布于 2012-03-17 04:46:49
在vcl_hit中,您可以执行以下操作:
if (req.http.Cache-Control ~ '\no-cache\b`) {
purge;
return (restart);
}确保已导入std vmod
import std;https://stackoverflow.com/questions/9727775
复制相似问题