diff options
| author | Luke Kanies <luke@reductivelabs.com> | 2009-12-21 16:23:44 -0800 |
|---|---|---|
| committer | Luke Kanies <luke@reductivelabs.com> | 2009-12-21 16:23:44 -0800 |
| commit | 740fd6b301af89ab3aad89bca183ad1fcdc24ac4 (patch) | |
| tree | f34617a229509c373d28d67abb453e7ae2136c39 /lib/puppet/indirector | |
| parent | 8971d8beae2c409f9052f27c3f80ad3bdfff4de2 (diff) | |
| parent | 4a06379f8770c164e42bcc410d874076c6e95f24 (diff) | |
| download | puppet-740fd6b301af89ab3aad89bca183ad1fcdc24ac4.tar.gz puppet-740fd6b301af89ab3aad89bca183ad1fcdc24ac4.tar.xz puppet-740fd6b301af89ab3aad89bca183ad1fcdc24ac4.zip | |
Merge branch '0.25.x'
Conflicts:
lib/puppet/agent.rb
lib/puppet/application/puppetd.rb
lib/puppet/parser/ast/leaf.rb
lib/puppet/util/rdoc/parser.rb
Diffstat (limited to 'lib/puppet/indirector')
| -rw-r--r-- | lib/puppet/indirector/catalog/active_record.rb | 5 | ||||
| -rw-r--r-- | lib/puppet/indirector/facts/facter.rb | 2 | ||||
| -rw-r--r-- | lib/puppet/indirector/ldap.rb | 2 | ||||
| -rw-r--r-- | lib/puppet/indirector/node/ldap.rb | 2 |
4 files changed, 8 insertions, 3 deletions
diff --git a/lib/puppet/indirector/catalog/active_record.rb b/lib/puppet/indirector/catalog/active_record.rb index e3b56ece6..575ce72fb 100644 --- a/lib/puppet/indirector/catalog/active_record.rb +++ b/lib/puppet/indirector/catalog/active_record.rb @@ -30,6 +30,11 @@ class Puppet::Resource::Catalog::ActiveRecord < Puppet::Indirector::ActiveRecord host.merge_resources(catalog.vertices) host.last_compile = Time.now + if node = Puppet::Node.find(catalog.name) + host.ip = node.parameters["ipaddress"] + host.environment = node.environment + end + host.save end end diff --git a/lib/puppet/indirector/facts/facter.rb b/lib/puppet/indirector/facts/facter.rb index 9df71fcac..6c6cbc6be 100644 --- a/lib/puppet/indirector/facts/facter.rb +++ b/lib/puppet/indirector/facts/facter.rb @@ -29,7 +29,7 @@ class Puppet::Node::Facts::Facter < Puppet::Indirector::Code Timeout::timeout(self.timeout) do load file end - rescue => detail + rescue Exception => detail Puppet.warning "Could not load fact file %s: %s" % [fqfile, detail] end end diff --git a/lib/puppet/indirector/ldap.rb b/lib/puppet/indirector/ldap.rb index 7485bd932..51bab0e6e 100644 --- a/lib/puppet/indirector/ldap.rb +++ b/lib/puppet/indirector/ldap.rb @@ -40,7 +40,7 @@ class Puppet::Indirector::Ldap < Puppet::Indirector::Terminus found = true yield entry end - rescue => detail + rescue Exception => detail if count == 0 # Try reconnecting to ldap if we get an exception and we haven't yet retried. count += 1 diff --git a/lib/puppet/indirector/node/ldap.rb b/lib/puppet/indirector/node/ldap.rb index 4600a0dd5..dd8cebfac 100644 --- a/lib/puppet/indirector/node/ldap.rb +++ b/lib/puppet/indirector/node/ldap.rb @@ -73,7 +73,7 @@ class Puppet::Node::Ldap < Puppet::Indirector::Ldap # The attributes that Puppet will stack as array over the full # hierarchy. - def stacked_attributes + def stacked_attributes(dummy_argument=:work_arround_for_ruby_GC_bug) Puppet[:ldapstackedattrs].split(/\s*,\s*/) end |
