easy-deployment 0.1.3 → 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/easy-deployment/version.rb +1 -1
- data/lib/easy/deployment/niet.rb +7 -5
- metadata +4 -4
data/lib/easy/deployment/niet.rb
CHANGED
@@ -2,25 +2,27 @@
|
|
2
2
|
# To load this capistrano configuraiton, require 'easy/deployment/niet' from deploy.rb
|
3
3
|
|
4
4
|
Capistrano::Configuration.instance(:must_exist).load do
|
5
|
+
set :niet_process_count, 2
|
6
|
+
|
5
7
|
namespace :niet do
|
6
8
|
desc "Setup Niet"
|
7
9
|
task :setup, roles: :job do
|
8
10
|
run "mkdir -p #{shared_path}/niet"
|
9
11
|
end
|
10
12
|
|
11
|
-
desc "Starts the niet process monitor"
|
13
|
+
desc "Starts the niet process monitor and its jobs"
|
12
14
|
task :start, roles: :job do
|
13
|
-
|
15
|
+
niet_process_count.times do |i|
|
14
16
|
run "niet -p #{shared_path}/niet/jobs_worker_#{i}.pid -c #{current_path} bundle exec rake jobs:work RAILS_ENV=#{stage}"
|
15
17
|
end
|
16
18
|
end
|
17
19
|
|
18
|
-
desc "Restarts the
|
20
|
+
desc "Restarts the processes running under niet"
|
19
21
|
task :restart, roles: :job do
|
20
|
-
run "for job in #{shared_path}/niet/* ; do kill `cat $job`; done"
|
22
|
+
run "for job in #{shared_path}/niet/* ; do kill -TERM `cat $job`; done"
|
21
23
|
end
|
22
24
|
|
23
|
-
desc "Stops the niet process monitor"
|
25
|
+
desc "Stops the processes running under niet and the niet process monitor"
|
24
26
|
task :stop, roles: :job do
|
25
27
|
run "for job in #{shared_path}/niet/* ; do kill -QUIT `cat $job`; done"
|
26
28
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: easy-deployment
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.4
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -12,7 +12,7 @@ authors:
|
|
12
12
|
autorequire:
|
13
13
|
bindir: bin
|
14
14
|
cert_chain: []
|
15
|
-
date: 2012-07-
|
15
|
+
date: 2012-07-15 00:00:00.000000000 Z
|
16
16
|
dependencies:
|
17
17
|
- !ruby/object:Gem::Dependency
|
18
18
|
name: rails
|
@@ -158,7 +158,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
158
158
|
version: '0'
|
159
159
|
segments:
|
160
160
|
- 0
|
161
|
-
hash: -
|
161
|
+
hash: -1451020214739844817
|
162
162
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
163
163
|
none: false
|
164
164
|
requirements:
|
@@ -167,7 +167,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
167
167
|
version: '0'
|
168
168
|
segments:
|
169
169
|
- 0
|
170
|
-
hash: -
|
170
|
+
hash: -1451020214739844817
|
171
171
|
requirements: []
|
172
172
|
rubyforge_project:
|
173
173
|
rubygems_version: 1.8.24
|