We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Hello,
I'm currently running rspec unit tests with puppet 8.10.0 and I get an error when calling filebeat class:
rspec
8.10.0
filebeat
puppet
class { 'filebeat': major_version => '7', package_ensure => 'latest', manage_repo => $manage_repo, beat_name => $facts['networking']['fqdn'], fields => { customer => $ccode, environment => $environment, }, outputs => { logstash => { hosts => $hosts, ttl => 300, timeout => 300, }, }, logging => { level => 'warning', to_syslog => true, metrics => { enabled => false, }, }, monitoring => { enabled => true, cluster_uuid =>'6k1fejSOQKO7oALvS-h9GA', # uuid sas-cluster elasticsearch => { sniffing => false, hosts => $monhosts, }, }, purge_conf_dir => $filebeat_purge_conf_dir, }
error
Puppet::PreformattedError: Evaluation Error: Error while evaluating a Resource Statement, Evaluation Error: Error while evaluating a Function Call, Failed to parse template filebeat/input.yml.erb: Filepath: /home/rook/.rbenv/versions/3.2.0/lib/ruby/gems/3.2.0/gems/puppet-8.10.0/lib/puppet/util/package.rb Line: 12 Detail: undefined method `scan' for nil:NilClass (file: /home/rook/git-repos/puppet-profiles/spec/fixtures/modules/filebeat/manifests/input.pp, line: 91, column: 25)
The error points to this resource declaration in filebeat/input.pp:
filebeat/input.pp
file { "filebeat-${name}": ensure => $ensure, path => "${filebeat::config_dir}/${name}.yml", owner => 'root', group => '0', mode => $filebeat::config_file_mode, content => template("${module_name}/${input_template}"), validate_cmd => $validate_cmd, notify => Service['filebeat'], require => File['filebeat.yml'], } }
more specifically:
content => template("${module_name}/${input_template}"),
The unit test works on puppet 7 but now breaks on puppet 8, what am I missing ?
Here's the declaration for filebeat module in .fixtures.yml:
.fixtures.yml
filebeat: repo: 'pcfens-filebeat' ref: '4.14.0'
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Hello,
I'm currently running
rspec
unit tests with puppet8.10.0
and I get an error when callingfilebeat
class:puppet
error
The error points to this resource declaration in
filebeat/input.pp
:more specifically:
The unit test works on puppet 7 but now breaks on puppet 8, what am I missing ?
Here's the declaration for filebeat module in
.fixtures.yml
:The text was updated successfully, but these errors were encountered: