302 redirect while accessing sentry from a reverse proxy on suburl

Hi
I’ve setup an onprem sentry V10 along with nginx proxy.

this is my config snippets
nginx config
location / {
proxy_pass http://<ip_addr>:8080;
}
here is my web settings
###########
# Web Server #
##############

SENTRY_WEB_HOST = '0.0.0.0'
SENTRY_WEB_PORT = 8080
SENTRY_WEB_OPTIONS = {
    'workers': 4,
}

when accessing with proxy this works fine but when i do this
location /sentry {
proxy_pass http://<ip_addr>:8080;
}
the sentry web throws a 302 redirect and nginx gives 404 error.
Jun 18 13:33:19 supervisord[125909]: sentry-web 1.2.3.4 - - [18/Jun/2020:13:33:19 +0000] "GET /sentry/ HTTP/1.0" 302 836 "-" "Mozilla/5.0

What am i missing here ?

Very likely you are missing this:

Thanks for suggestion but that didn’t worked. is it possible that some config params are missing in sentry web server configuration (see config listed in my question )?

You may be missing the system.url-prefix setting in config.yml: https://develop.sentry.dev/config/#general

That didn’t worked either.

Maybe if you share more detailed logs from nginx and sentry, we may find the issue easier.