Grafana panel integration?

I have a couple of Grafana panels that I thought would like decent as a custom tile in sharptools, but they don’t seem to work. I have tried to either imbed as an iframe or just use the URL of the public panel.

The public panel (which is a countdown of the buses at my nearest London bus stop, generated from the TfL API) is here:

https://skinnypope231.grafana.net/public-dashboards/524b7b96e19d42329ee63d858cf5009d?orgId=1&refresh=10s

I’m guessing these don’t “play nice” with Sharptools?

It looks like that particular URL doesn’t play nice being embedded. Is there a separate setting or URL that Grafana provides for embedded URLs?

From the browser console logs, it looks like Grafana is setting a header that blocks the page being embedded:

Refused to display 'https://skinnypope231.grafana.net/' in a frame because it set 'X-Frame-Options' to 'deny'.

Thanks Josh, that’s really helpful. It turns out there is indeed a config setting for allowing embedding, however it’s buried in a config file that only is accessible to local installs of Grafana (not the cloud version I was on).

When I get time I’ll install locally and hopefully clear this up.

Thanks again.

1 Like

Well I have installed locally and enabled embedding, but I now see the image blocked, this is in the console:

vendor-vue-aa36f558.js:5 Mixed Content: The page at 'https://sharptools.io/dashboard/view/11NsphNQqGgLRBp1esVP' was loaded over HTTPS, but requested an insecure frame 'http://[redacted]:3000/public-dashboards/177c566b1fc84f359d3315ce75f7cdbb?orgId=1&refresh=10s'. This request has been blocked; the content must be served over HTTPS.

I can’t see a setting to load the dashboard over https in Grafana - feels like the end of the road?

There’s a few approaches you could take:

  1. Setup SSL for your Grafana dashboards with a valid cert (eg. not self-signed)

    Set up Grafana HTTPS for secure web traffic | Grafana documentation

  2. Allow Mixed Content in your web browser

    Google Chrome - Mixed Content - Media Not Showing

1 Like