Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Configuring puppetdb as a hiera_backend #74

Open
divansantana opened this issue Jan 25, 2016 · 1 comment
Open

Configuring puppetdb as a hiera_backend #74

divansantana opened this issue Jan 25, 2016 · 1 comment

Comments

@divansantana
Copy link
Contributor

One can configure puppetdb as a hiera_backend as per https://github.com/dalen/puppet-puppetdbquery#hiera-backend

However I'm not sure that it's currently possible to do this using this module as it expects a hash.

You'd expect this to work like so:

puppet::profile::master::hiera_backends:
  yaml:
    datadir: "/etc/puppet/environments/%{environment}/hiera"
  eyaml:
    datadir: "/etc/puppet/environments/%{environment}/hiera"
  puppetdb:

However breaks with:

Error: Failed to parse template puppet/hiera.yaml.erb:
  Filepath: /root/modules/puppet/templates/hiera.yaml.erb
  Line: 15
  Detail: undefined method `keys' for nil:NilClass
 at /root/modules/puppet/manifests/master/hiera.pp:22 on node node.example.co.za
Error: Failed to parse template puppet/hiera.yaml.erb:
  Filepath: /root/modules/puppet/templates/hiera.yaml.erb
  Line: 15
  Detail: undefined method `keys' for nil:NilClass
 at /root/modules/puppet/manifests/master/hiera.pp:22 on node node.example.co.za
@divansantana
Copy link
Contributor Author

Unless one can use this syntax:

puppet::profile::master::hiera_backends:
  puppetdb:
    datasource: data

I'll test this out and see if it works.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant