golden_brindle 0.1 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- data/golden_brindle.gemspec +2 -2
- data/lib/golden_brindle/configure.rb +2 -2
- data/lib/golden_brindle/const.rb +1 -1
- data/lib/golden_brindle/start.rb +8 -4
- metadata +2 -2
data/golden_brindle.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{golden_brindle}
|
8
|
-
s.version = "0.1"
|
8
|
+
s.version = "0.1.1"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Alexander Simonov"]
|
12
|
-
s.date = %q{2011-
|
12
|
+
s.date = %q{2011-09-02}
|
13
13
|
s.default_executable = %q{golden_brindle}
|
14
14
|
s.description = %q{Unicorn HTTP server multiple application runner tool}
|
15
15
|
s.email = %q{alex@simonov.me}
|
@@ -11,12 +11,12 @@ module Brindle
|
|
11
11
|
['', "--preload", "Preload application", :@preload, false],
|
12
12
|
['-p', '--port PORT', "Which port to bind to (if set numbers of servers - start port number)", :@port, Unicorn::Const::DEFAULT_PORT],
|
13
13
|
['-a', '--address ADDR', "Address to bind to", :@address, Unicorn::Const::DEFAULT_HOST],
|
14
|
-
['-o', '--listen {HOST:PORT|PATH}',"listen on HOST:PORT or PATH,
|
14
|
+
['-o', '--listen {HOST:PORT|PATH}',"listen on HOST:PORT or PATH, separated by comma ", :@listen, nil] ,
|
15
15
|
['-l', '--log FILE', "Where to write log messages", :@log_file, "log/unicorn.log"],
|
16
16
|
['-P', '--pid FILE', "Where to write the PID", :@pid_file, "tmp/pids/unicorn.pid"],
|
17
17
|
['-n', '--num-workers INT', "Number of Unicorn workers", :@workers, 4],
|
18
18
|
['-N', '--num-servers INT', "Number of Unicorn listen records", :@servers, 1],
|
19
|
-
['-t', '--timeout
|
19
|
+
['-t', '--timeout INT', "Time to wait (in seconds) before killing a stalled thread", :@timeout, 60],
|
20
20
|
['-c', '--chdir PATH', "Change to dir before starting (will be expanded)", :@cwd, Dir.pwd],
|
21
21
|
['-D', '--debug', "Enable debugging mode", :@debug, false],
|
22
22
|
['-C', '--config PATH', "Path to brindle configuration file", :@config_file, "config/brindle.yml"],
|
data/lib/golden_brindle/const.rb
CHANGED
data/lib/golden_brindle/start.rb
CHANGED
@@ -12,12 +12,12 @@ module Brindle
|
|
12
12
|
['', "--preload", "Preload application", :@preload, false],
|
13
13
|
['-p', '--port PORT', "Which port to bind to (if set numbers of servers - start port number)", :@port, Unicorn::Const::DEFAULT_PORT],
|
14
14
|
['-a', '--address ADDR', "Address to bind to", :@address, Unicorn::Const::DEFAULT_HOST],
|
15
|
-
['-o', '--listen {HOST:PORT|PATH}',"listen on HOST:PORT or PATH,
|
15
|
+
['-o', '--listen {HOST:PORT|PATH}',"listen on HOST:PORT or PATH, separated by comma (default: #{Unicorn::Const::DEFAULT_LISTEN})", :@listen, Unicorn::Const::DEFAULT_LISTEN],
|
16
16
|
['-l', '--log FILE', "Where to write log messages", :@log_file, "log/unicorn.log"],
|
17
17
|
['-P', '--pid FILE', "Where to write the PID", :@pid_file, "tmp/pids/unicorn.pid"],
|
18
18
|
['-n', '--num-workers INT', "Number of Unicorn workers", :@workers, 4],
|
19
19
|
['-N', '--num-servers INT', "Number of Unicorn listen records", :@servers, 1],
|
20
|
-
['-t', '--timeout
|
20
|
+
['-t', '--timeout INT', "Time to wait (in seconds) before killing a stalled thread", :@timeout, 60],
|
21
21
|
['-c', '--chdir PATH', "Change to dir before starting (will be expanded)", :@cwd, Dir.pwd],
|
22
22
|
['-D', '--debug', "Enable debugging mode", :@debug, false],
|
23
23
|
['-C', '--config PATH', "Use a mongrel based config file", :@config_file, nil],
|
@@ -149,7 +149,7 @@ module Brindle
|
|
149
149
|
:config_file => @config_script,
|
150
150
|
:worker_processes => @workers.to_i,
|
151
151
|
:working_directory => @cwd,
|
152
|
-
:timeout => @timeout
|
152
|
+
:timeout => @timeout.to_i
|
153
153
|
}
|
154
154
|
# set user via Unicorn options. If we don't set group - then use only user
|
155
155
|
options[:user] = @user unless @user.nil?
|
@@ -223,7 +223,11 @@ module Brindle
|
|
223
223
|
Unicorn::Launcher.daemonize!(options)
|
224
224
|
end
|
225
225
|
puts "start Unicorn..."
|
226
|
-
Unicorn.run
|
226
|
+
if Unicorn.respond_to?(:run)
|
227
|
+
Unicorn.run(app, options)
|
228
|
+
else
|
229
|
+
Unicorn::HttpServer.new(app, options).start.join
|
230
|
+
end
|
227
231
|
end
|
228
232
|
|
229
233
|
|
metadata
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
name: golden_brindle
|
3
3
|
version: !ruby/object:Gem::Version
|
4
4
|
prerelease:
|
5
|
-
version:
|
5
|
+
version: 0.1.1
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
8
8
|
- Alexander Simonov
|
@@ -10,7 +10,7 @@ autorequire:
|
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
12
|
|
13
|
-
date: 2011-
|
13
|
+
date: 2011-09-02 00:00:00 +03:00
|
14
14
|
default_executable: golden_brindle
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|