"export for sharing externally" seems to be broken

Hi,

I am trying to share/upload a dashboard so others can download it. But I am not having much luck.

So first off, when I download/copy the json from my Grafana install (Dashboard settings) and save it, the upload form says, “Old dashboard JSON format” and I can’t continue to upload.

This error I don’t understand, because I am literally doing this with Grafana 10.x. I created this dashboard from scratch this morning — there should be nothing “old” about it.

I get the same error when I do it via export.

When I select “export for sharing externally”, then the Dashboard import “works”, but it contains references to my currently selected datasource, which I do not want to expose/disclose. :slight_smile: And that part is probably also not extremely helpful when people import it.

For reference, the “datasource” is a variable in my case since I have multiple datasources configured in my Grafana install.

Just edit that dashboard json manually and remove those preselected/default values with your datasource names.

Still think this is a bug. :smiley: Maybe someone can file it.

To work around it:

  • I made inputs an empty list
  • I replaced the datasource previously in inputs, with my variable ($datasource)

It would be nice if this could be improved. Also not the smoothest transaction to share dashboards outside of this place here when they come with hardcoded datasources, etc…

Yes, it’s annoying bug. I reported it while ago, but audience for this bug is very small, so it was not prioritised.
Anyway, you can open pull request to fix it and you will have high chance that it will be accepted and merged into main branch.

Do you have a link to the bug? I‘ll subscribe at least.

1 Like

I recreated your issue — the circle of life completed. :rofl:

Thanks for helping out, @jangaraj

1 Like