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

Invalid Kafo-generated hiera.conf #87

Open
mattock opened this issue Mar 20, 2019 · 1 comment
Open

Invalid Kafo-generated hiera.conf #87

mattock opened this issue Mar 20, 2019 · 1 comment

Comments

@mattock
Copy link
Member

mattock commented Mar 20, 2019

Recently the installer has started failing with these errors:

[ERROR 2019-03-20T05:45:35 main] Errors encountered during run:
[ERROR 2019-03-20T05:45:35 main]  Evaluation Error: Error while evaluating a Function Call, Lookup of key 'lookup_options' failed:  The Lookup Configuration a
t '/tmp/kafo_hiera20190320-5670-iw2i8y/hiera.conf' has wrong type, unrecognized key 'backends'

The offending hiera.conf looks like this:

---
:backends:
- yaml
:hierarchy:
- "%{::osfamily}"
- common
:yaml:
  :datadir: "/usr/share/puppetmaster-installer/config/data"
version: 5
defaults:
  datadir: "/tmp/kafo_hiera20190320-6062-di2vrb/data"
  data_hash: yaml_data
hierarchy:
- name: Kafo Answers
  path: kafo_answers.yaml
  datadir: "/tmp/kafo_hiera20190320-6062-di2vrb/data"
  data_hash: yaml_data
@mattock
Copy link
Member Author

mattock commented Mar 20, 2019

This can be reproduced trivially using the above hiera.conf without Kafo:

$ puppet apply --hiera_config=/tmp/hiera.conf -e 'notify { lookup('foo'): }'
Error: Evaluation Error: Error while evaluating a Function Call, Lookup of key 'lookup_options' failed: 
The Lookup Configuration at '/tmp/hiera.conf' has wrong type, unrecognized key 'backends'
The Lookup Configuration at '/tmp/hiera.conf' has wrong type, unrecognized key 'yaml' 
(line: 1, column: 10) on node localhost.

mattock added a commit that referenced this issue Mar 20, 2019
The puppet-kafo module is not used outside of this installer and is quite
simplistic. Therefore move its code into kafo.pp into this installer.

URL: #87
Signed-off-by: Samuli Seppänen <[email protected]>
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