How to configure 'Root URL'?

I’m confused with ‘Root URL’, this domain should be public or private? such as ‘http://domain.com’ or ‘http://192.168.0.1’?

Thank you very much.

Its whatever URL you’re using to access it, as thats the URL it will use to generate links.

yes, i can use this URL i’m using to access it, as my ROOT URL. It work fine with me, but PUBLIC DSN. The PRIVATE DSN is expected for me, for some situation.

i want access sentry with PUBLIC DSN from FE such as website, and access sentry with PRIVATE DSN from BE such as application running in my private cloud server. if i change the ROOT URL to PUBLIC, i got PUBLIC DSN only in page /sentry/PROJECT/settings/keys/.

so, give me some suggestion, please…

The DSN has nothing to do with the URL other than your app needs to be able to talk to the host. In an upcoming release of Sentry the “private” DSN (that is, the DSN which includes the secret key) will no longer be required (or used) by SDKs. Until then you simply need to set the DSN based on whichever SDK you’re using, and if you want it to use some internal hostname in some situation then change the hostname (you cant change the UI to customize this).

I 'm sorry to bother you. I am a newer to use sentry.
I set an incorrect Root Url fro sentry. How to reset Root Url?
(install Sentry through On-Premise)

You can use the ‘sentry config’ command to change options. system.url-prefix is the option name

1 Like

@zeeg I don’t believe this config option works for the redirect from “/” to “/auth/login/{project_name}” when logged out, which causes problems when using a proxy in front. It tries to redirect to localhost:9000/auth/login/{project_name}. Any ideas?

If the redirect isnt respecting the URL prefix then we should probably fix that (assuming its a bug). As long as its proxying per a spec it generally should respect that just fine:

I figured out my issue. Our proxy was filtering out the Host header. Sentry or Django is using this for redirects.