puppet-collectd icon indicating copy to clipboard operation
puppet-collectd copied to clipboard

Unknown variable collectd_version

Open fnoop opened this issue 7 years ago • 2 comments

Affected Puppet, Ruby, OS and module versions/distributions

  • Puppet: 5.2.0
  • Ruby: 2.3.3p222
  • Distribution: Ubuntu 17.04 zesty
  • Module version: 6.0.0

How to reproduce (e.g Puppet code you use)

class { "collectd": config_file => $config_file, plugin_conf_dir => $plugin_conf_dir, plugin_conf_dir_mode => "755", purge => true, recurse => true, purge_config => true, minimum_version => '5.7', manage_package => $manage_package, manage_repo => $manage_repo, manage_service => true, service_name => 'maverick-collectd', typesdb => [$typesdb], }

What are you seeing

Error: Evaluation Error: Unknown variable: '::collectd_version'. at /srv/maverick/software/maverick/manifests/puppet-modules/collectd/manifests/init.pp:37:33 on node maverick-ubuntu17

Any additional information you'd like to impart

puppet is being run as a local standalone process (puppet apply), not as client/server. Worked fine with version 5.3.0 of this module

fnoop avatar Oct 24 '17 09:10 fnoop

The problem occurs when strict_variables are enabled in the puppetmaster configuration: https://puppet.com/docs/puppet/5.2/configuration.html#strictvariables

When the fact is empty when collectd is not installed (that's the case on the first puppet run with this module) it fails.

crigertg avatar Nov 03 '17 14:11 crigertg

Hi @fnoop ,

PR #708 merged yesterday. Can you give a try in your environment?

btravouillon avatar Nov 08 '17 00:11 btravouillon