Nginx location matches
NginxNginx LocationNginx Problem Overview
What is the difference between:
location = /abc {}
and
locaton ~ /abc {}
Nginx Solutions
Solution 1 - Nginx
location = /abc {}
matches the exact uri /abc
location ~ /abc
is a regex match on the uri, meaning any uri containing /abc
,
you probably want: location ~ ^/abc
for the uri begining with /abc
instead