nginx的if判断,怎样调试nginx查看日志

nginx.cof

if ($request_filename = config.js) {
                add_header Cache-Control "private, no-store, no-cache, must-revalidate, proxy-revalidate";
            }
        这句if里写的对吗,如何调试这种简单的判断
阅读 1.5k
1 个回答

curl命令呗,把response header打出来看看有没有:

curl -s -o /dev/null -D - http://localhost:8080/config.js

希望能帮助到你。

撰写回答
你尚未登录,登录后可以
  • 和开发者交流问题的细节
  • 关注并接收问题和回答的更新提醒
  • 参与内容的编辑和改进,让解决方法与时俱进
推荐问题