Feature #18553
openSet Puppet 4/5 data types during class import
Description
This may be a potential feature request rather than a bug but wanted to file as a bug as it's currently causing issues within my new deployment.
Disclaimer: I'm new to Foreman and puppet 4. I come from a puppet 2.5 environment.
I've deployed Foreman via AIO. Additionally I've deployed a Puppet Open Source environment independent from Foreman.
In both environments, I've installed the module puppetlabs-ntp (version 6.0.0).
In the Foreman environment after assigning the class to a host group, I get the following messages on the client:
Error: Could not retrieve catalog from remote server: Error 500 on SERVER: Server Error: Evaluation Error: Error while evaluating a Resource Statement, Class[Ntp]:
parameter 'config' expects a match for Variant[Stdlib::Windowspath = Pattern[/^(([a-zA-Z]:[\\\/])|([\\\/][\\\/][^\\\/]+[\\\/][^\\\/]+)|([\\\/][\\\/]\?[\\\/][^\\\/]+))/], Stdlib::Unixpath = Pattern[/^\/([^\/\0]+(\/)?)+$/]], got ''
parameter 'config_dir' expects a match for Variant[Stdlib::Windowspath = Pattern[/^(([a-zA-Z]:[\\\/])|([\\\/][\\\/][^\\\/]+[\\\/][^\\\/]+)|([\\\/][\\\/]\?[\\\/][^\\\/]+))/], Stdlib::Unixpath = Pattern[/^\/([^\/\0]+(\/)?)+$/]], got ''
parameter 'disable_auth' expects a Boolean value, got String
parameter 'disable_kernel' expects a Boolean value, got String
parameter 'fudge' expects an Array value, got String
parameter 'driftfile' expects a match for Variant[Stdlib::Windowspath = Pattern[/^(([a-zA-Z]:[\\\/])|([\\\/][\\\/][^\\\/]+[\\\/][^\\\/]+)|([\\\/][\\\/]\?[\\\/][^\\\/]+))/], Stdlib::Unixpath = Pattern[/^\/([^\/\0]+(\/)?)+$/]], got ''
parameter 'leapfile' expects a match for Variant[Stdlib::Windowspath = Pattern[/^(([a-zA-Z]:[\\\/])|([\\\/][\\\/][^\\\/]+[\\\/][^\\\/]+)|([\\\/][\\\/]\?[\\\/][^\\\/]+))/], Stdlib::Unixpath = Pattern[/^\/([^\/\0]+(\/)?)+$/]], got ''
parameter 'logfile' expects a match for Variant[Stdlib::Windowspath = Pattern[/^(([a-zA-Z]:[\\\/])|([\\\/][\\\/][^\\\/]+[\\\/][^\\\/]+)|([\\\/][\\\/]\?[\\\/][^\\\/]+))/], Stdlib::Unixpath = Pattern[/^\/([^\/\0]+(\/)?)+$/]], got ''
parameter 'iburst_enable' expects a Boolean value, got String
parameter 'keys' expects an Array value, got String
parameter 'keys_enable' expects a Boolean value, got String
parameter 'keys_file' expects a match for Variant[Stdlib::Windowspath = Pattern[/^(([a-zA-Z]:[\\\/])|([\\\/][\\\/][^\\\/]+[\\\/][^\\\/]+)|([\\\/][\\\/]\?[\\\/][^\\\/]+))/], Stdlib::Unixpath = Pattern[/^\/([^\/\0]+(\/)?)+$/]], got ''
parameter 'keys_controlkey' expects a Ntp::Key_id = Integer[1, 65534] value, got String
parameter 'keys_requestkey' expects a Ntp::Key_id = Integer[1, 65534] value, got String
parameter 'keys_trusted' expects an Array value, got String
parameter 'minpoll' expects a Ntp::Poll_interval = Integer[4, 17] value, got String
parameter 'maxpoll' expects a Ntp::Poll_interval = Integer[4, 17] value, got String
parameter 'package_manage' expects a Boolean value, got String
parameter 'package_name' expects an Array value, got String
parameter 'panic' expects an Integer value, got String
parameter 'peers' expects an Array value, got String
parameter 'preferred_servers' expects an Array value, got String
parameter 'restrict' expects an Array value, got String
parameter 'interfaces' expects an Array value, got String
parameter 'interfaces_ignore' expects an Array value, got String
parameter 'service_enable' expects a Boolean value, got String
parameter 'service_manage' expects a Boolean value, got String
parameter 'stepout' expects an Integer value, got String
parameter 'step_tickers_file' expects a match for Variant[Stdlib::Windowspath = Pattern[/^(([a-zA-Z]:[\\\/])|([\\\/][\\\/][^\\\/]+[\\\/][^\\\/]+)|([\\\/][\\\/]\?[\\\/][^\\\/]+))/], Stdlib::Unixpath = Pattern[/^\/([^\/\0]+(\/)?)+$/]], got ''
parameter 'tinker' expects a Boolean value, got String
parameter 'tos' expects a Boolean value, got String
parameter 'tos_minclock' expects an Integer value, got String
parameter 'tos_minsane' expects an Integer value, got String
parameter 'tos_floor' expects an Integer value, got String
parameter 'tos_ceiling' expects an Integer value, got String
parameter 'tos_cohort' expects a value of type Boolean or Integer, got String
parameter 'udlc' expects a Boolean value, got String
parameter 'udlc_stratum' expects an Integer value, got String
parameter 'ntpsigndsocket' expects a match for Variant[Stdlib::Windowspath = Pattern[/^(([a-zA-Z]:[\\\/])|([\\\/][\\\/][^\\\/]+[\\\/][^\\\/]+)|([\\\/][\\\/]\?[\\\/][^\\\/]+))/], Stdlib::Unixpath = Pattern[/^\/([^\/\0]+(\/)?)+$/]], got '' on node
I can eliminate the messages by reassigning key types within the smart parameter class. Is there a way to pull in the parameter type from within the module to ensure these are correct? Or am I doing something incorrectly?
As a note this also functions properly within puppet enterprise.
Updated by Ivan Revchuk almost 8 years ago
Hello. All
I have the same problem.
As I see, after installed ntp plugin, all NTP Smart Class Parameters mark as override default behavior and value set NILL.
For testing, i disabled all 53 parameters and plugin start work correct.
Please, fix this bug.
Updated by Dominic Cleal almost 8 years ago
- Related to Bug #18564: Class parameters using module data defaults should not have override enabled on import added
Updated by Dominic Cleal almost 8 years ago
- Tracker changed from Bug to Feature
- Subject changed from Parameter Key Type incorrect when importing modules to Set Puppet 4.x data types during class import
- Category set to Puppet integration
Yes, this is a feature request but an advanced one to support all of the known data types.
Ivan, the issue you're describing is different, so I filed it under #18564.
Updated by Anonymous about 7 years ago
- Has duplicate Feature #21813: Puppet import of parameter types in classes added
Updated by Marek Hulán over 6 years ago
- Related to Feature #24419: puppet class - parse and honour puppet 5 variable definitions added
Updated by Marek Hulán over 6 years ago
- Subject changed from Set Puppet 4.x data types during class import to Set Puppet 4/5 data types during class import