voxpupuli / puppet-grafana

Puppet module to manage Grafana
Apache License 2.0
15 stars 106 forks source link

Resources ignoring organization parameter #279

Open none0nfg opened 2 years ago

none0nfg commented 2 years ago

Affected Puppet, Ruby, OS and module versions/distributions

How to reproduce (e.g Puppet code you use)

Dashboards, Folders, Datasources ignoring organization param

      grafana_organization { 'SUT':
        ensure           => present,
        grafana_password => $admin_password,
        id               => 2,
      }

      grafana_datasource { 'Prometheus':
        ensure           => present,
        type             => 'prometheus',
        access_mode      => 'proxy',
        organization     => 2,
        is_default       => true,
      }

      grafana_folder { 'SUT_Dashboards':
        ensure           => present,
        organization     => 2,
        require          => [Grafana_organization['SUT']]
      }

      grafana_dashboard { 'Node_exporter':
        ensure           => present,
        folder           => 'Dashboards',
        organization     => 'SUT',
      }

I've remove some fields.

What are you seeing

Resources creates in MainOrg

What behaviour did you expect instead

Resources will be created in org with id 2 or name SUT

Output log

Nothig. resources created, but in another org

Any additional information you'd like to impart