capistrano-delayed_job 0.0.4 → 0.0.5
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile +1 -1
- data/Gemfile.lock +2 -2
- data/README.md +26 -3
- data/VERSION +1 -1
- data/capistrano-delayed_job.gemspec +5 -5
- data/lib/capistrano/delayed_job/runit.rb +1 -1
- metadata +5 -5
data/Gemfile
CHANGED
data/Gemfile.lock
CHANGED
@@ -9,7 +9,7 @@ GEM
|
|
9
9
|
net-sftp (>= 2.0.0)
|
10
10
|
net-ssh (>= 2.0.14)
|
11
11
|
net-ssh-gateway (>= 1.1.0)
|
12
|
-
capistrano-base_helper (0.0.
|
12
|
+
capistrano-base_helper (0.0.7)
|
13
13
|
capistrano (>= 2.15.5)
|
14
14
|
faraday (0.8.7)
|
15
15
|
multipart-post (~> 1.1)
|
@@ -65,5 +65,5 @@ PLATFORMS
|
|
65
65
|
DEPENDENCIES
|
66
66
|
bundler (>= 1.3.0)
|
67
67
|
capistrano (>= 2.15.5)
|
68
|
-
capistrano-base_helper (>= 0.0.
|
68
|
+
capistrano-base_helper (>= 0.0.7)
|
69
69
|
jeweler (~> 1.8.6)
|
data/README.md
CHANGED
@@ -7,7 +7,7 @@ This gem provides recipes for [Delayed Job](https://github.com/collectiveidea/de
|
|
7
7
|
Add it to your Gemfile without requiring it
|
8
8
|
|
9
9
|
```ruby
|
10
|
-
gem 'capistrano-delayed_job'
|
10
|
+
gem 'capistrano-delayed_job', :require => false
|
11
11
|
```
|
12
12
|
|
13
13
|
In your deploy.rb:
|
@@ -18,7 +18,7 @@ require 'capistrano/delayed_job'
|
|
18
18
|
|
19
19
|
### Monit
|
20
20
|
|
21
|
-
```
|
21
|
+
```
|
22
22
|
cap delayed_job:monit:disable # Disable and stop monit services for Delayed Job
|
23
23
|
cap delayed_job:monit:enable # Enable monit services for Delayed Job
|
24
24
|
cap delayed_job:monit:monitor # Monitor Delayed Job
|
@@ -29,9 +29,18 @@ cap delayed_job:monit:stop # Stop monit services for Delayed Job (wi
|
|
29
29
|
cap delayed_job:monit:unmonitor # Purge Delayed Job monit configuration
|
30
30
|
```
|
31
31
|
|
32
|
-
|
32
|
+
#### Setup in your deploy file
|
33
|
+
|
34
|
+
You can add this to deploy.rb or env.rb in order to automatically start/stop puma using monit. It is not needed if you use runit to stop/start/restart the service.
|
33
35
|
|
34
36
|
```ruby
|
37
|
+
before "monit:unmonitor", "delayed_job:monit:stop"
|
38
|
+
after "monit:monitor", "delayed_job:monit:start"
|
39
|
+
```
|
40
|
+
|
41
|
+
### Runit
|
42
|
+
|
43
|
+
```
|
35
44
|
cap delayed_job:runit:disable # Disable Delayed Job runit-service
|
36
45
|
cap delayed_job:runit:enable # Enable Delayed Job runit-service
|
37
46
|
cap delayed_job:runit:flush_sockets # Flush delayed_job sockets, as they can end up 'han...
|
@@ -44,6 +53,20 @@ cap delayed_job:runit:start # Start Delayed Job runit-service
|
|
44
53
|
cap delayed_job:runit:stop # Stop Delayed Job runit-service
|
45
54
|
```
|
46
55
|
|
56
|
+
#### Setup in your deploy file
|
57
|
+
|
58
|
+
To use runit to start/stop/restart services instead of monit, use the example below.
|
59
|
+
|
60
|
+
```ruby
|
61
|
+
# stop before deployment
|
62
|
+
# (must be done after monit has stopped monitoring the task. If not, the service will be restarted by monit)
|
63
|
+
before "monit:unmonitor", "delayed_job:runit:stop"
|
64
|
+
# start before enabling monitor
|
65
|
+
before "monit:monitor", "delayed_job:runit:start"
|
66
|
+
# restart before enabling monitor / monitoring has been started
|
67
|
+
before "monit:monitor", "delayed_job:runit:restart"
|
68
|
+
```
|
69
|
+
|
47
70
|
## Configuration
|
48
71
|
|
49
72
|
See delayed_job/config.rb for default options, and ovveride any in your deploy.rb file.
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.0.
|
1
|
+
0.0.5
|
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = "capistrano-delayed_job"
|
8
|
-
s.version = "0.0.
|
8
|
+
s.version = "0.0.5"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Leif Ringstad"]
|
12
|
-
s.date = "2013-07-
|
12
|
+
s.date = "2013-07-29"
|
13
13
|
s.description = "Capistrano recipes for Delayed Job using runit and monit."
|
14
14
|
s.email = "leifcr@gmail.com"
|
15
15
|
s.extra_rdoc_files = [
|
@@ -44,18 +44,18 @@ Gem::Specification.new do |s|
|
|
44
44
|
|
45
45
|
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
46
46
|
s.add_runtime_dependency(%q<capistrano>, [">= 2.15.5"])
|
47
|
-
s.add_runtime_dependency(%q<capistrano-base_helper>, [">= 0.0.
|
47
|
+
s.add_runtime_dependency(%q<capistrano-base_helper>, [">= 0.0.7"])
|
48
48
|
s.add_development_dependency(%q<bundler>, [">= 1.3.0"])
|
49
49
|
s.add_development_dependency(%q<jeweler>, ["~> 1.8.6"])
|
50
50
|
else
|
51
51
|
s.add_dependency(%q<capistrano>, [">= 2.15.5"])
|
52
|
-
s.add_dependency(%q<capistrano-base_helper>, [">= 0.0.
|
52
|
+
s.add_dependency(%q<capistrano-base_helper>, [">= 0.0.7"])
|
53
53
|
s.add_dependency(%q<bundler>, [">= 1.3.0"])
|
54
54
|
s.add_dependency(%q<jeweler>, ["~> 1.8.6"])
|
55
55
|
end
|
56
56
|
else
|
57
57
|
s.add_dependency(%q<capistrano>, [">= 2.15.5"])
|
58
|
-
s.add_dependency(%q<capistrano-base_helper>, [">= 0.0.
|
58
|
+
s.add_dependency(%q<capistrano-base_helper>, [">= 0.0.7"])
|
59
59
|
s.add_dependency(%q<bundler>, [">= 1.3.0"])
|
60
60
|
s.add_dependency(%q<jeweler>, ["~> 1.8.6"])
|
61
61
|
end
|
@@ -9,7 +9,7 @@ Capistrano::Configuration.instance(true).load do
|
|
9
9
|
# enable service after update in case it has not been setup or is disabled
|
10
10
|
# Service should probably be started as well?
|
11
11
|
after "deploy:update", "delayed_job:runit:enable"
|
12
|
-
|
12
|
+
before "delayed_job:runit:quit", "delayed_job:runit:stop"
|
13
13
|
|
14
14
|
namespace :delayed_job do
|
15
15
|
namespace :runit do
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: capistrano-delayed_job
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.5
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-07-
|
12
|
+
date: 2013-07-29 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: capistrano
|
@@ -34,7 +34,7 @@ dependencies:
|
|
34
34
|
requirements:
|
35
35
|
- - ! '>='
|
36
36
|
- !ruby/object:Gem::Version
|
37
|
-
version: 0.0.
|
37
|
+
version: 0.0.7
|
38
38
|
type: :runtime
|
39
39
|
prerelease: false
|
40
40
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -42,7 +42,7 @@ dependencies:
|
|
42
42
|
requirements:
|
43
43
|
- - ! '>='
|
44
44
|
- !ruby/object:Gem::Version
|
45
|
-
version: 0.0.
|
45
|
+
version: 0.0.7
|
46
46
|
- !ruby/object:Gem::Dependency
|
47
47
|
name: bundler
|
48
48
|
requirement: !ruby/object:Gem::Requirement
|
@@ -113,7 +113,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
113
113
|
version: '0'
|
114
114
|
segments:
|
115
115
|
- 0
|
116
|
-
hash: -
|
116
|
+
hash: -4442654335854389884
|
117
117
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
118
118
|
none: false
|
119
119
|
requirements:
|