diff options
| author | luke <luke@980ebf18-57e1-0310-9a29-db15c13687c0> | 2006-05-18 22:16:03 +0000 |
|---|---|---|
| committer | luke <luke@980ebf18-57e1-0310-9a29-db15c13687c0> | 2006-05-18 22:16:03 +0000 |
| commit | 5671ce8bbc6eb75664190a7a2fe4b195ee31d4b7 (patch) | |
| tree | ad60e819920884794907d3cdca673895ebaf36d2 /lib/puppet | |
| parent | b3ea53cd99df84a93fe2f093d2224e711f49e5dd (diff) | |
| download | puppet-5671ce8bbc6eb75664190a7a2fe4b195ee31d4b7.tar.gz puppet-5671ce8bbc6eb75664190a7a2fe4b195ee31d4b7.tar.xz puppet-5671ce8bbc6eb75664190a7a2fe4b195ee31d4b7.zip | |
Added the last of the tests for the runner, along with the necessary work in puppetd to be able to start it.
git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1213 980ebf18-57e1-0310-9a29-db15c13687c0
Diffstat (limited to 'lib/puppet')
| -rw-r--r-- | lib/puppet/client.rb | 2 | ||||
| -rw-r--r-- | lib/puppet/server.rb | 12 | ||||
| -rw-r--r-- | lib/puppet/transaction.rb | 7 |
3 files changed, 16 insertions, 5 deletions
diff --git a/lib/puppet/client.rb b/lib/puppet/client.rb index f1884ac85..fbc9b5e9e 100644 --- a/lib/puppet/client.rb +++ b/lib/puppet/client.rb @@ -9,11 +9,9 @@ module Puppet # but at least it's better organized for now class Client include Puppet - include SignalObserver include Puppet::Util - # FIXME The cert stuff should only come up with networking, so it # should be in the network client, not the normal client. But if i do # that, it's hard to tell whether the certs have been initialized. diff --git a/lib/puppet/server.rb b/lib/puppet/server.rb index 7bdd21134..62137f8cf 100644 --- a/lib/puppet/server.rb +++ b/lib/puppet/server.rb @@ -27,6 +27,14 @@ module Puppet class Server < WEBrick::HTTPServer include Puppet::Daemon + Puppet.config.setdefaults(:puppetd, + :listen => [false, "Whether puppetd should listen for + connections. If this is true, then by default only the + ``runner`` server is started, which allows remote authorized + and authenticated nodes to connect and trigger ``puppetd`` + runs."] + ) + # Create our config object if necessary. This works even if # there's no configuration file. def authconfig @@ -121,8 +129,9 @@ module Puppet end def self.handler(name) + name = name.to_s.downcase @subclasses.find { |h| - h.name == name + h.name.to_s.downcase == name } end @@ -179,6 +188,7 @@ require 'puppet/server/ca' require 'puppet/server/fileserver' require 'puppet/server/filebucket' require 'puppet/server/pelement' +require 'puppet/server/runner' require 'puppet/server/logger' require 'puppet/client' diff --git a/lib/puppet/transaction.rb b/lib/puppet/transaction.rb index a451d85d4..f5410d642 100644 --- a/lib/puppet/transaction.rb +++ b/lib/puppet/transaction.rb @@ -108,7 +108,10 @@ class Transaction if tags.nil? or tags == "" tags = nil else - tags = tags.split(/\s*,\s*/) + tags = [tags] unless tags.is_a? Array + tags = tags.collect do |tag| + tag.split(/\s*,\s*/) + end.flatten end allevents = @objects.collect { |child| @@ -118,7 +121,7 @@ class Transaction # Perform the actual changes events = apply(child) - # Collect the targets any subscriptions to those events + # Collect the targets of any subscriptions to those events collecttargets(events) else child.debug "Not scheduled" |
