diff options
author | luke <luke@980ebf18-57e1-0310-9a29-db15c13687c0> | 2006-09-06 04:49:45 +0000 |
---|---|---|
committer | luke <luke@980ebf18-57e1-0310-9a29-db15c13687c0> | 2006-09-06 04:49:45 +0000 |
commit | e309b76e168f83e27cf541dc19a02c5b25c1e47c (patch) | |
tree | f5849a38377df2d719646c438d43ccdb9a99702f /lib/puppet/client/master.rb | |
parent | c5ce953462f424138f0009ce978eb9620aff84a7 (diff) | |
download | puppet-e309b76e168f83e27cf541dc19a02c5b25c1e47c.tar.gz puppet-e309b76e168f83e27cf541dc19a02c5b25c1e47c.tar.xz puppet-e309b76e168f83e27cf541dc19a02c5b25c1e47c.zip |
Modifying the provider base class so that it defines a method for every used command (e.g., you call "commands :rpm => 'rpm'", and it defines an "rpm" method. I then pushed this throughout the package providers, which are the heaviest users of commands.
git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1571 980ebf18-57e1-0310-9a29-db15c13687c0
Diffstat (limited to 'lib/puppet/client/master.rb')
-rw-r--r-- | lib/puppet/client/master.rb | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/lib/puppet/client/master.rb b/lib/puppet/client/master.rb index 8ab251728..19d301f7d 100644 --- a/lib/puppet/client/master.rb +++ b/lib/puppet/client/master.rb @@ -564,7 +564,14 @@ class Puppet::Client::MasterClient < Puppet::Client end end ensure - Facter.loadfacts + if Facter.respond_to? :loadfacts + Facter.loadfacts + elsif Facter.respond_to? :load + Facter.load + else + raise Puppet::Error, + "You must upgrade your version of Facter to use centralized facts" + end end # Retrieve the plugins from the central server. We only have to load the |