nginx的多个location都匹配到了请求,那么怎么知道具体走的是哪个location?
有没有什么日志可以打印出来是哪个location匹配的?
`
location ^~ /test {
rewrite ^/test/(.*) /test/aaa/$1;
}
location ^~ /test/a2 {
rewrite ^/test/(.*) /test/aaa/$1;
}
`
类似以上的,访问 http://xx/test/a2/xxx ,日志中怎么打印是走的哪个location呢?
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…