Provision Grafana datasources in different authorization teams/organizations

  • What Grafana version and what operating system are you using?
    Using Latest Grafana 10.x

  • What are you trying to achieve?
    Provision datasources with different authorization teams/roles/orgs whatever works.

  • How are you trying to achieve it?
    I provision datasources by adding a configuration file (YAML) in the provision/datasources folder but I don’t know how to divide them in different authorization teams/org. I works fine if I manually create organizations and then divide the datasources in the different organizations and then restart grafana. But I want this to be automated without manual steps and it would be awesome there is a way to define organizations in a configuration file. I have not found anything atleast.

  • What happened?
    As mentioned above, I had to ad manual steps but I want it to be automated with configuration files.

  • What did you expect to happen?
    I hoped that organizations could be configured in a YAML file.

For deploying I am using Azure webapps and terraform and I know that there is a terraform provider for Grafana which is using the Grafana API but I rather configure grafana from startup.
The reason is that the network is not always supporting terraform to reach the grafana service which will fail to create terraform resources.

Maybe dividing the datasources in organizations is not the way forward? Happy for other suggestions.

Best regards
Dimitrios