I have an app with endpoint http://localhost:3000/seller/ and I use nginx proxy_pass
server {
include default_proxy_headers;
listen 80;
listen 443 ssl http2;
listen [::]:443 ssl http2;
server_name domain.my;
location /seller {
proxy_buffering off;
proxy_pass http://localhost:3000;
}
location /seller/api {
rewrite /seller/(.*) /$1 break;
proxy_pass http://localhost:5000;
proxy_buffering off;
}
}
It works as I expected with https://domain.my/seller/ - thats OK.
If I'm trying to use https://domain.my/seller (without "/" slash at the end) it redirects to https://domain.my:3000/seller/.
How to disable redirecting to ":3000" port? I want it to work only as https://domain.my/seller/ (with / slash at the end).