NGINX
NGINX Trac
3rd Party Modules
Security Advisories
CHANGES
OpenResty
ngx_lua
Tengine
在线学习资源
NGINX 开发从入门到精通
NGINX Modules
ngx_echo
holinhot
V2EX  ›  NGINX

nginx 缓存配置问题请教

  •  
  •   holinhot · Sep 22, 2016 · 2593 views
    This topic created in 3544 days ago, the information mentioned may be changed or developed.
    http://doanloads.v2ex.com/test.zip?key=11111

    这个下载文件配置一个反向代理服务器+缓存。用户每次下载的地址不一样,但是文件是一样的。这样怎么配置缓存规则让代理服务器把 test.zip?key=xxxxx test.zip?key=11111 和 test.zip?key=22222 test.zip?key=3333....当一个文件来缓存。
    holinhot
        1
    holinhot  
    OP
       Sep 22, 2016
    已解决。
    proxy_cache_key $scheme$proxy_host$uri; 查找缓存把后缀去掉就行了
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   923 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 26ms · UTC 22:50 · PVG 06:50 · LAX 15:50 · JFK 18:50
    ♥ Do have faith in what you're doing.