Jim Ficarra
2014-Jun-17 17:51 UTC
[Puppet Users] Chocolatey pre-fetch fails with Puppet - Could not prefetch package provider 'chocolatey': undefined method `each' for nil:NilClass
Chocolatey is installed as a shared module on the puppet master. Below is
the specific part of the puppet code that uses the chocolatey provider to
install a custom package.
class install_carbon {
package {'carbon':
ensure => '1.7',
provider => 'chocolatey',
}
}
This class is part of a larger set of modules and classes that work
together and execute completely and successfully on another host but fails
on a second host with the error below. Same puppet client version (3.4.2
installed from an internal NuGet repo). Chocolatey is also customized to
point to an internal repo.
Any help/thoughts/insight would be appreciated.
Thanks!
Could not prefetch package provider 'chocolatey': undefined method
`each'
for nil:NilClass
C:/Tools/Puppet/puppet/lib/puppet/provider/package.rb:4:in `prefetch'
C:/Tools/Puppet/puppet/lib/puppet/transaction.rb:277:in `prefetch'
C:/Tools/Puppet/puppet/lib/puppet/transaction.rb:167:in
`prefetch_if_necessary'
C:/Tools/Puppet/puppet/lib/puppet/transaction.rb:67:in `block in evaluate'
C:/Tools/Puppet/puppet/lib/puppet/graph/relationship_graph.rb:116:in `call'
C:/Tools/Puppet/puppet/lib/puppet/graph/relationship_graph.rb:116:in
`traverse'
C:/Tools/Puppet/puppet/lib/puppet/transaction.rb:108:in `evaluate'
C:/Tools/Puppet/puppet/lib/puppet/resource/catalog.rb:164:in `block in
apply'
C:/Tools/Puppet/puppet/lib/puppet/util/log.rb:149:in `with_destination'
C:/Tools/Puppet/puppet/lib/puppet/transaction/report.rb:108:in
`as_logging_destination'
C:/Tools/Puppet/puppet/lib/puppet/resource/catalog.rb:163:in `apply'
C:/Tools/Puppet/puppet/lib/puppet/configurer.rb:125:in `block in
apply_catalog'
C:/Tools/Puppet/puppet/lib/puppet/util.rb:161:in `block in benchmark'
C:/Tools/Puppet/sys/ruby/lib/ruby/1.9.1/benchmark.rb:295:in `realtime'
C:/Tools/Puppet/puppet/lib/puppet/util.rb:160:in `benchmark'
C:/Tools/Puppet/puppet/lib/puppet/configurer.rb:124:in `apply_catalog'
C:/Tools/Puppet/puppet/lib/puppet/configurer.rb:192:in `run'
C:/Tools/Puppet/puppet/lib/puppet/agent.rb:44:in `block (4 levels) in run'
C:/Tools/Puppet/puppet/lib/puppet/agent/locker.rb:20:in `lock'
C:/Tools/Puppet/puppet/lib/puppet/agent.rb:44:in `block (3 levels) in run'
C:/Tools/Puppet/puppet/lib/puppet/agent.rb:114:in `with_client'
C:/Tools/Puppet/puppet/lib/puppet/agent.rb:41:in `block (2 levels) in run'
C:/Tools/Puppet/puppet/lib/puppet/agent.rb:79:in `run_in_fork'
C:/Tools/Puppet/puppet/lib/puppet/agent.rb:40:in `block in run'
C:/Tools/Puppet/puppet/lib/puppet/application.rb:179:in `call'
C:/Tools/Puppet/puppet/lib/puppet/application.rb:179:in `controlled_run'
C:/Tools/Puppet/puppet/lib/puppet/agent.rb:38:in `run'
C:/Tools/Puppet/puppet/lib/puppet/application/agent.rb:355:in `onetime'
C:/Tools/Puppet/puppet/lib/puppet/application/agent.rb:321:in `run_command'
C:/Tools/Puppet/puppet/lib/puppet/application.rb:364:in `block (2 levels)
in run'
C:/Tools/Puppet/puppet/lib/puppet/application.rb:470:in `plugin_hook'
C:/Tools/Puppet/puppet/lib/puppet/application.rb:364:in `block in run'
C:/Tools/Puppet/puppet/lib/puppet/util.rb:478:in `exit_on_fail'
C:/Tools/Puppet/puppet/lib/puppet/application.rb:364:in `run'
C:/Tools/Puppet/puppet/lib/puppet/util/command_line.rb:137:in `run'
C:/Tools/Puppet/puppet/lib/puppet/util/command_line.rb:91:in `execute'
C:/Tools/Puppet/puppet/bin/puppet:4:in `<main>'
--
You received this message because you are subscribed to the Google Groups
"Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to puppet-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/puppet-users/ed1ffcb8-f3da-4079-ae8b-d115a08f9d5a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.