You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am having some problems overriding facts that affect Hiera. This only happens when I upgrade to 2.7.0. As I am working on Puppet 6.11 support for this repo, I assume I have no other choice. On Puppet 5 and 2.4.0 all of our tests pass.
We would then have a default context and one override. For example:
context'with default values for all parameters'doit{is_expected.tocontain_class('profiles::baseline')}endcontext'running on physical'dobeforedofacts.merge!(virtual: 'physical')end# it is expected to have some physical resource available hereend
The 'running on physical' always fails.
I have tried to switch our implementation over to use the default_facts configuration setting but this didn't work. None of the facts seemed to be coming through.
It seems to be a problem with data coming from Hiera. It might be the order in which facts are loaded. The facts that we merge often affect where to get data from. The virtual fact points to a specific yaml file. We were still using Hiera 3, but converting this to 5 makes no difference. It fails on data that is definitely available in Hiera, works in production and passes tests on Puppet 5 and pre-2.7 versions of rspec-puppet.
Does this sound familiar? Any suggestions I could look at?
The text was updated successfully, but these errors were encountered:
I am having some problems overriding facts that affect Hiera. This only happens when I upgrade to 2.7.0. As I am working on Puppet 6.11 support for this repo, I assume I have no other choice. On Puppet 5 and 2.4.0 all of our tests pass.
Our facts are loaded with:
We would then have a default context and one override. For example:
The 'running on physical' always fails.
I have tried to switch our implementation over to use the default_facts configuration setting but this didn't work. None of the facts seemed to be coming through.
It seems to be a problem with data coming from Hiera. It might be the order in which facts are loaded. The facts that we merge often affect where to get data from. The
virtual
fact points to a specific yaml file. We were still using Hiera 3, but converting this to 5 makes no difference. It fails on data that is definitely available in Hiera, works in production and passes tests on Puppet 5 and pre-2.7 versions of rspec-puppet.Does this sound familiar? Any suggestions I could look at?
The text was updated successfully, but these errors were encountered: