背景 我们在配置nginx的nginx.conf文件中,会存在location配置项,一般我们会在大括号{}中配置的参数有:proxy_pass、root、alias。 这里有一个问题:这些参数的属性值末尾处加不加斜杠“/”,在nginx跳转时不会拼接上location里的路径?如图: 试验结果记录 问:加"/“和不加”/"时,跳转会不会拼接上location里的路径? 答: 参数项加"/"不加"/"proxy_pass不会会root会会alias不会会报错 例子: