Grafana URL inserted two times in URL address

  • What Grafana version and what operating system are you using?

    • Grafana 13.0.1 on a Docker container in Ubuntu 24.04.4 LTS
  • What are you trying to achieve?

  • How are you trying to achieve it?

    • SERVER DOMAIN, SERVER ROOT, and SERVER FROM SUB_PATH are configured as an environment variables:
  • What happened?

  • What did you expect to happen?

  • Can you copy/paste the configuration(s) that you are having problems with?

    • My Grafana.ini is has NO other configurations apart from the env variables shown before, but I am attaching the relevant parts. Also attaching the GF variables file.
    • This error appears with or without a Reverse Proxy. I am currently testing WITHOUT a proxy.
    • Grafana.ini
    ##################### Grafana Configuration Defaults 
    
    #################################### Server ##############################
    [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 = 3000
    
    # The public facing domain name used to access grafana from a browser
    #domain = testserver.diedo.local
    
    # Redirect to correct domain if host header does not match domain
    # Prevents DNS rebinding attacks
    ;enforce_domain = false
    
    # The full public facing url
    ;root_url = %(protocol)s://%(domain)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
    
    # Log web requests
    ;router_logging = false
    
    # the path relative working path
    ;static_root_path = public
    
    # enable gzip
    ;enable_gzip = false
    
    # https certs & key file
    #cert_file = /etc/grafana/cert.cer
    #cert_key = /etc/grafana/private.key
    
    # Unix socket gid
    # Changing the gid of a file without privileges requires that the target group is in the group of the process and that the process is the file owner
    # It is recommended to set the gid as http server user gid
    # Not set when the value is -1
    ;socket_gid = -1
    
    # Unix socket mode
    ;socket_mode = 0660
    
    # Unix socket path
    ;socket = /tmp/grafana.sock
    
    # CDN Url
    ;cdn_url =
    
    # Sets the maximum time in minutes before timing out read of an incoming request and closing idle connections.
    # `0` means there is no timeout for reading the request.
    ;read_timeout = 0
    
    # This setting enables you to specify additional headers that the server adds to HTTP(S) responses.
    [server.custom_response_headers]
    #exampleHeader1 = exampleValue1
    #exampleHeader2 = exampleValue2
    
    
    
  • Did you receive any errors in the Grafana UI or in related logs? If so, please tell us exactly what they were.

    • No logs in grafana
  • Did you follow any online instructions? If so, what is the URL?

please try this
Trailing slash add
GF_SERVER_ROOT_URL=http://testserver.diedo.loc:3000/grafana/
GF_SERVER_SERVE_FROM_SUB_PATH=true
and then restart the grafana service.
also clear the browser cache.

Thank you for your reply @infofcc3 . I tested your suggestion:

Restarted Grafana, cleared up the browser cache, but behavior is the same. When I enter the URL and press enter:

image

I adds the host part to the URL:

This was a configuration error on my grafana.ini.Closing.