summaryrefslogtreecommitdiffstats
path: root/lib/puppet.rb
diff options
context:
space:
mode:
authorluke <luke@980ebf18-57e1-0310-9a29-db15c13687c0>2006-10-16 03:54:18 +0000
committerluke <luke@980ebf18-57e1-0310-9a29-db15c13687c0>2006-10-16 03:54:18 +0000
commitdad596e6c5e241607eee92e54890b53affeba02b (patch)
treecacf10af8e832f5d3b7248dd6437465e6e23e317 /lib/puppet.rb
parent9a8636c3c22ca5b7d244e1a80e9c2bf8b4dffe8f (diff)
downloadpuppet-dad596e6c5e241607eee92e54890b53affeba02b.tar.gz
puppet-dad596e6c5e241607eee92e54890b53affeba02b.tar.xz
puppet-dad596e6c5e241607eee92e54890b53affeba02b.zip
Fixing #291 -- the problem was that instead of throwing an error on a missing server, puppet was just exiting.
git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1785 980ebf18-57e1-0310-9a29-db15c13687c0
Diffstat (limited to 'lib/puppet.rb')
-rw-r--r--lib/puppet.rb12
1 files changed, 6 insertions, 6 deletions
diff --git a/lib/puppet.rb b/lib/puppet.rb
index 71c7743a7..7d21e8c3d 100644
--- a/lib/puppet.rb
+++ b/lib/puppet.rb
@@ -289,12 +289,12 @@ module Puppet
# waiting for someone, somewhere, to generate events of some kind.
def self.start(block = true)
# Starting everything in its own thread, fwiw
- defined? @services and @services.each do |svc|
+ defined? @services and @services.dup.each do |svc|
newthread do
begin
svc.start
rescue => detail
- if Puppet[:debug]
+ if Puppet[:trace]
puts detail.backtrace
end
@services.delete svc
@@ -303,15 +303,15 @@ module Puppet
end
end
+ # We need to give the services a chance to register their timers before
+ # we try to start monitoring them.
+ sleep 0.5
+
unless @services.length > 0
Puppet.notice "No remaining services; exiting"
exit(1)
end
- # We need to give the services a chance to register their timers before
- # we try to start monitoring them.
- sleep 0.5
-
if defined? @timers and ! @timers.empty?
@timers.each do |timer|
EventLoop.current.monitor_timer timer