Nginx rewrite rule with proxy pass Nginx rewrite rule with proxy pass nginx nginx

Nginx rewrite rule with proxy pass


Your rewrite statement is wrong.

The $1 on the right refers to a group (indicated by paratheses) in the matching section.

Try:

rewrite  ^/Shep.ElicenseWeb/(.*)  /$1 break;


You're missing a trailing slash:

location /Shep.ElicenseWeb/ {    proxy_pass http://localhost:82/;}

This will work without a rewrite.