Hello people,
I’ve been trying to configure the Grafana on IIS using reverse proxy but without success.
I followed the steps in the documentation ( Use IIS with URL Rewrite as a reverse proxy | Grafana Labs) and watch a tutorial (Grafana and IIS - Windows Server Installation Setup and Configuration - YouTube), but, I always have the error ERR_TOO_MANY_REDIRECTS in the browser.
Grafana version: 10.0.1.
My custom.ini config:
[server]
# Protocol (http, https, h2, socket)
protocol = http
# The ip address to bind to, empty will bind to all interfaces
;http_addr =
# The http port to use
http_port = 8080
# The public facing domain name used to access grafana from a browser
domain = localhost
# Redirect to correct domain if host header does not match domain
# Prevents DNS rebinding attacks
;enforce_domain = false
# The full public facing url you use in browser, used for redirects and emails
# If you use reverse proxy and sub path specify full url (with sub path)
root_url = %(protocol)s://%(domain)s:%(http_port)s/grafana/
# Serve Grafana from subpath specified in `root_url` setting. By default it is set to `false` for compatibility reasons.
serve_from_sub_path = true
My web.config:
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<rewrite>
<rules>
<rule name="Grafana Inbound Rule" enabled="true" stopProcessing="true">
<match url="grafana(/)?(.*)" />
<action type="Rewrite" url="http://localhost:8080{R:2}" logRewrittenUrl="false" />
</rule>
</rules>
</rewrite>
</system.webServer>
</configuration>
I don’t know what happens so I need help.
Thanks