bluepill 0.0.48 → 0.0.49

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -218,6 +218,8 @@ You can run bluepill in the foreground:
218
218
  # ...
219
219
  end
220
220
 
221
+ Note that You must define only one application per config when using foreground mode.
222
+
221
223
  ## Links
222
224
  Code: [http://github.com/arya/bluepill](http://github.com/arya/bluepill)
223
225
  Bugs/Features: [http://github.com/arya/bluepill/issues](http://github.com/arya/bluepill/issues)
data/Rakefile CHANGED
@@ -1,4 +1,9 @@
1
1
  # encoding: utf-8
2
2
 
3
- require 'bundler'
4
- Bundler::GemHelper.install_tasks
3
+ begin
4
+ require 'bundler'
5
+ Bundler::GemHelper.install_tasks
6
+ rescue LoadError
7
+ $stderr.puts "Bundler not installed. You should install it with: gem install bundler"
8
+ end
9
+
data/bluepill.gemspec CHANGED
@@ -19,6 +19,8 @@ Gem::Specification.new do |s|
19
19
  s.add_dependency 'activesupport', '>= 3.0.0'
20
20
  s.add_dependency 'i18n', '>= 0.5.0'
21
21
 
22
+ s.add_development_dependency 'bundler', '>= 1.0.10'
23
+
22
24
  s.files = `git ls-files`.split("\n")
23
25
  s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
24
26
  s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
@@ -1,4 +1,8 @@
1
1
  # -*- encoding: utf-8 -*-
2
+
3
+ # fixes problem with loading on systems with rubyist-aasm installed
4
+ gem "state_machine"
5
+
2
6
  require "state_machine"
3
7
  require "daemons"
4
8
 
@@ -25,6 +29,8 @@ module Bluepill
25
29
  :uid,
26
30
  :gid,
27
31
 
32
+ :cache_actual_pid,
33
+
28
34
  :monitor_children,
29
35
  :child_process_factory
30
36
  ]
@@ -106,6 +112,7 @@ module Bluepill
106
112
 
107
113
  # These defaults are overriden below if it's configured to be something else.
108
114
  @monitor_children = false
115
+ @cache_actual_pid = true
109
116
  @start_grace_time = @stop_grace_time = @restart_grace_time = 3
110
117
  @environment = {}
111
118
 
@@ -326,8 +333,13 @@ module Bluepill
326
333
  false
327
334
  end
328
335
 
336
+ def cache_actual_pid?
337
+ !!@cache_actual_pid
338
+ end
339
+
329
340
  def actual_pid
330
- @actual_pid ||= begin
341
+ return @actual_pid if cache_actual_pid? && @actual_pid
342
+ @actual_pid = begin
331
343
  if pid_file
332
344
  if File.exists?(pid_file)
333
345
  str = File.read(pid_file)
@@ -1,4 +1,4 @@
1
1
  # -*- encoding: utf-8 -*-
2
2
  module Bluepill
3
- VERSION = "0.0.48".freeze
3
+ VERSION = "0.0.49".freeze
4
4
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bluepill
3
3
  version: !ruby/object:Gem::Version
4
- hash: 127
4
+ hash: 125
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 48
10
- version: 0.0.48
9
+ - 49
10
+ version: 0.0.49
11
11
  platform: ruby
12
12
  authors:
13
13
  - Arya Asemanfar
@@ -17,7 +17,7 @@ autorequire:
17
17
  bindir: bin
18
18
  cert_chain: []
19
19
 
20
- date: 2011-04-07 00:00:00 +04:00
20
+ date: 2011-05-14 00:00:00 +04:00
21
21
  default_executable:
22
22
  dependencies:
23
23
  - !ruby/object:Gem::Dependency
@@ -84,6 +84,22 @@ dependencies:
84
84
  version: 0.5.0
85
85
  type: :runtime
86
86
  version_requirements: *id004
87
+ - !ruby/object:Gem::Dependency
88
+ name: bundler
89
+ prerelease: false
90
+ requirement: &id005 !ruby/object:Gem::Requirement
91
+ none: false
92
+ requirements:
93
+ - - ">="
94
+ - !ruby/object:Gem::Version
95
+ hash: 3
96
+ segments:
97
+ - 1
98
+ - 0
99
+ - 10
100
+ version: 1.0.10
101
+ type: :development
102
+ version_requirements: *id005
87
103
  description: Bluepill keeps your daemons up while taking up as little resources as possible. After all you probably want the resources of your server to be used by whatever daemons you are running rather than the thing that's supposed to make sure they are brought back up, should they die or misbehave.
88
104
  email:
89
105
  - entombedvirus@gmail.com