diff options
author | Luke Kanies <luke@madstop.com> | 2009-02-13 21:06:34 -0600 |
---|---|---|
committer | James Turnbull <james@lovedthanlost.net> | 2009-02-14 22:42:51 +1100 |
commit | 84bd5285db5a80b01dd0359387516210ccb5b625 (patch) | |
tree | b2b160bccff29984b05732d21b6f9d65b6faa337 /lib | |
parent | d5abdfba8a88afda8085992a4abbe1d90bbd0084 (diff) | |
download | puppet-84bd5285db5a80b01dd0359387516210ccb5b625.tar.gz puppet-84bd5285db5a80b01dd0359387516210ccb5b625.tar.xz puppet-84bd5285db5a80b01dd0359387516210ccb5b625.zip |
Actualling syncing facts and plugins
Also fixing the argument order while downloading
either of them. I had my Downloader.new
calls using the wrong argument order.
Signed-off-by: Luke Kanies <luke@madstop.com>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/puppet/configurer.rb | 2 | ||||
-rw-r--r-- | lib/puppet/configurer/fact_handler.rb | 4 | ||||
-rw-r--r-- | lib/puppet/configurer/plugin_handler.rb | 2 |
3 files changed, 6 insertions, 2 deletions
diff --git a/lib/puppet/configurer.rb b/lib/puppet/configurer.rb index 67c744d39..b29082d5a 100644 --- a/lib/puppet/configurer.rb +++ b/lib/puppet/configurer.rb @@ -124,6 +124,8 @@ class Puppet::Configurer # This just passes any options on to the catalog, # which accepts :tags and :ignoreschedules. def run(options = {}) + prepare() + unless catalog = retrieve_catalog Puppet.err "Could not retrieve catalog; skipping run" return diff --git a/lib/puppet/configurer/fact_handler.rb b/lib/puppet/configurer/fact_handler.rb index 9435cb22a..d0e890f62 100644 --- a/lib/puppet/configurer/fact_handler.rb +++ b/lib/puppet/configurer/fact_handler.rb @@ -1,5 +1,7 @@ require 'puppet/indirector/facts/facter' +require 'puppet/configurer/downloader' + # Break out the code related to facts. This module is # just included into the agent, but having it here makes it # easier to test. @@ -23,7 +25,7 @@ module Puppet::Configurer::FactHandler def download_fact_plugins return unless download_fact_plugins? - Puppet::Configurer::Downloader.new("fact", Puppet[:factsource], Puppet[:factdest], Puppet[:factsignore]).evaluate + Puppet::Configurer::Downloader.new("fact", Puppet[:factdest], Puppet[:factsource], Puppet[:factsignore]).evaluate end # Clear out all of the loaded facts and reload them from disk. diff --git a/lib/puppet/configurer/plugin_handler.rb b/lib/puppet/configurer/plugin_handler.rb index cadf300fd..def6a1707 100644 --- a/lib/puppet/configurer/plugin_handler.rb +++ b/lib/puppet/configurer/plugin_handler.rb @@ -9,7 +9,7 @@ module Puppet::Configurer::PluginHandler # Retrieve facts from the central server. def download_plugins return nil unless download_plugins? - Puppet::Configurer::Downloader.new("plugin", Puppet[:pluginsource], Puppet[:plugindest], Puppet[:pluginsignore]).evaluate.each { |file| load_plugin(file) } + Puppet::Configurer::Downloader.new("plugin", Puppet[:plugindest], Puppet[:pluginsource], Puppet[:pluginsignore]).evaluate.each { |file| load_plugin(file) } end def load_plugin(file) |