diff options
| author | Nick Lewis <nick@puppetlabs.com> | 2010-12-16 11:34:09 -0800 |
|---|---|---|
| committer | Nick Lewis <nick@puppetlabs.com> | 2010-12-16 11:34:09 -0800 |
| commit | a2ff092d8302e09aa79f9bb16636f8298316c3c7 (patch) | |
| tree | cb67d36e37e252edceef1cd848cc32d679f5d20e /lib/puppet/network/handler | |
| parent | 4b35402ba85d8842d757becec5c8a7bf4d6f6654 (diff) | |
| parent | 480c399f183627f5f588e9dc9f5f86f683c0e468 (diff) | |
| download | puppet-a2ff092d8302e09aa79f9bb16636f8298316c3c7.tar.gz puppet-a2ff092d8302e09aa79f9bb16636f8298316c3c7.tar.xz puppet-a2ff092d8302e09aa79f9bb16636f8298316c3c7.zip | |
Merge branch 'next'
Diffstat (limited to 'lib/puppet/network/handler')
| -rwxr-xr-x | lib/puppet/network/handler/filebucket.rb | 4 | ||||
| -rwxr-xr-x | lib/puppet/network/handler/fileserver.rb | 2 | ||||
| -rw-r--r-- | lib/puppet/network/handler/master.rb | 4 |
3 files changed, 5 insertions, 5 deletions
diff --git a/lib/puppet/network/handler/filebucket.rb b/lib/puppet/network/handler/filebucket.rb index 6aaa2df1c..55028ee64 100755 --- a/lib/puppet/network/handler/filebucket.rb +++ b/lib/puppet/network/handler/filebucket.rb @@ -28,12 +28,12 @@ class Puppet::Network::Handler # :nodoc: def addfile(contents, path, client = nil, clientip = nil) contents = Base64.decode64(contents) if client bucket = Puppet::FileBucket::File.new(contents) - bucket.save + Puppet::FileBucket::File.indirection.save(bucket) end # Return the contents associated with a given md5 sum. def getfile(md5, client = nil, clientip = nil) - bucket = Puppet::FileBucket::File.find("md5:#{md5}") + bucket = Puppet::FileBucket::File.indirection.find("md5:#{md5}") contents = bucket.contents if client diff --git a/lib/puppet/network/handler/fileserver.rb b/lib/puppet/network/handler/fileserver.rb index 9abc7ee1a..5b4b17a32 100755 --- a/lib/puppet/network/handler/fileserver.rb +++ b/lib/puppet/network/handler/fileserver.rb @@ -236,7 +236,7 @@ class Puppet::Network::Handler unless hostname = (client || Facter.value("hostname")) raise ArgumentError, "Could not find hostname" end - env = (node = Puppet::Node.find(hostname)) ? node.environment : nil + env = (node = Puppet::Node.indirection.find(hostname)) ? node.environment : nil # And use the environment to look up the module. (mod = Puppet::Node::Environment.new(env).module(module_name) and mod.files?) ? @mounts[MODULES].copy(mod.name, mod.file_directory) : nil diff --git a/lib/puppet/network/handler/master.rb b/lib/puppet/network/handler/master.rb index c21aafafc..62aab539e 100644 --- a/lib/puppet/network/handler/master.rb +++ b/lib/puppet/network/handler/master.rb @@ -47,9 +47,9 @@ class Puppet::Network::Handler client ||= facts["hostname"] # Pass the facts to the fact handler - Puppet::Node::Facts.new(client, facts).save unless local? + Puppet::Node::Facts.indirection.save(Puppet::Node::Facts.new(client, facts)) unless local? - catalog = Puppet::Resource::Catalog.find(client) + catalog = Puppet::Resource::Catalog.indirection.find(client) case format when "yaml" |
