Grafana behind a reverse proxy -> how to change links to public facing links?

Hi,

I have a grafana setup that is behind a public facing reverse proxy (nginx).
Grafana binds to localhost @ random port (i.e., not accessible from public).

My Grafana setup is sending out emails with verification links like this:
You can also copy/paste this link into your browser directly: http://grafana.staged-by-discourse.com/invite/
How do I configure it to send links (and everything else of relevance) with public facing URLs?

Thanks,
Kiru

You need to set root_url in the [server] section of your grafana config file.

I’m having the same problem. I’m running grafana in a kubernetes cluster. I am using cloudflare DNS and pointing to an ingress controller. The grafana ingress object matches my cloudflare DNS record to the grafana service in our cluster. If I set root_url to the value of our DNS record I get an error from firefox saying the page is not redirecting properly. Any idea how to solve this? If I leave it as localhost it works but the link in the invite e-mail is broken. It’s the only thing not working.

The above link helped me figure out my problem. Posting in case anyone else sees this thread and has the same problem I did. The issue was my ingress object configuration.