Cannot access IPv6 datasource of Prometheus

  • What Grafana version and what operating system are you using?
    Grafana v10.3.1 (00a22ff8b2)

  • What are you trying to achieve?
    I have a IPv6 based prometheus service behind nginx and I was trying to add it as datasource in grafana. Prometheus access URL: https:///prometheus/

  • How are you trying to achieve it?
    I have a grafana container v10.3.1 running and configure a yaml file to grafana’s /etc/grafana/provisioning/datasources/ as a datasource. My yaml file:

apiVersion: 1
deleteDatasources:
  - name: Prometheus
    orgId: 1
datasources:
  - name: PrometheusDataSource
    type: prometheus
    access: proxy
    orgId: 1
    url: https://[<IPv6 address>]/prometheus/
    isDefault: true
    jsonData:
      tlsSkipVerify: true
    editable: false
  • What happened?
    Data source added in grafana but cannot access. get error message:
"Post "https://[<IPv6 address>]/prometheus/api/v1/query": dial tcp [<IPv6 address>]:443: connect: cannot assign requested address - There was an error returned querying the Prometheus API."
  • What did you expect to happen?
    I can add above Prometheus as datasource in grafana and successful fetch data from it

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

  • Did you receive any errors in the Grafana UI or in related logs? If so, please tell us exactly what they were.
    Yes, post the error message in above questions.

  • Did you follow any online instructions? If so, what is the URL?
    tried to google it but nothing useful found.

Does you container support IPv6?