luban-monit 0.1.5 → 0.1.6
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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +7 -0
- data/lib/luban/deployment/packages/monit/controller.rb +17 -13
- data/lib/luban/deployment/packages/monit/installer.rb +1 -1
- data/lib/luban/deployment/packages/monit/templates/monit.logrotate.erb +0 -4
- data/lib/luban/deployment/packages/monit/templates/monitrc.erb +0 -4
- data/lib/luban/deployment/packages/monit/version.rb +1 -1
- data/lib/luban/deployment/packages/monit.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 528e39a60a87cf41762668340bc94a5ffca4c0b2
|
4
|
+
data.tar.gz: a6d998bf1b4d944390087db2e05b36c3b755a24b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d5a5ef11d817a6a7f22b34ab57eb442827655fb1d2dbfd259868657328015d5fae095e8c8f28df90537a5ea40f8cf99aa1100aa65d18f436464cedeb4ee3ca23
|
7
|
+
data.tar.gz: d9934e991727e72c69be109c273e4f9832d815b14df2ff95cdffa18053d246811791244bfb4bb513ab94f4e4cf0c0322784a012b95a48faef1feb8ca73628b21
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,12 @@
|
|
1
1
|
# Change log
|
2
2
|
|
3
|
+
## Version 0.1.6 (Jun 16, 2016)
|
4
|
+
|
5
|
+
Minor enhancements:
|
6
|
+
* Refatored commands definitions for better reusability among service workers
|
7
|
+
* Simplified erb templates by removing header information like revision, environment, etc.
|
8
|
+
* Header info is generated by Luban (with a generic header template which could be customized if needed)
|
9
|
+
|
3
10
|
## Version 0.1.5 (Jun 08, 2016)
|
4
11
|
|
5
12
|
Minor enhancements:
|
@@ -3,12 +3,24 @@ module Luban
|
|
3
3
|
module Packages
|
4
4
|
class Monit
|
5
5
|
class Controller < Luban::Deployment::Service::Controller
|
6
|
-
|
6
|
+
module Commands
|
7
|
+
def self.included(base)
|
8
|
+
base.define_executable 'monit'
|
9
|
+
end
|
7
10
|
|
8
|
-
|
9
|
-
|
11
|
+
def monit_command
|
12
|
+
@monit_command ||= "#{monit_executable}"
|
13
|
+
end
|
14
|
+
|
15
|
+
alias_method :process_pattern, :monit_command
|
16
|
+
alias_method :start_command, :monit_command
|
17
|
+
|
18
|
+
def stop_command
|
19
|
+
@stop_command ||= "#{monit_command} quit"
|
20
|
+
end
|
10
21
|
end
|
11
|
-
|
22
|
+
|
23
|
+
include Commands
|
12
24
|
|
13
25
|
def process_stopped?
|
14
26
|
super and check_process! =~ /the monit daemon is not running$/
|
@@ -36,14 +48,6 @@ module Luban
|
|
36
48
|
capture("#{monit_command} -t 2>&1")
|
37
49
|
end
|
38
50
|
|
39
|
-
def start_process!
|
40
|
-
capture("#{monit_command} 2>&1")
|
41
|
-
end
|
42
|
-
|
43
|
-
def stop_process!
|
44
|
-
capture("#{monit_command} quit 2>&1")
|
45
|
-
end
|
46
|
-
|
47
51
|
def check_process!
|
48
52
|
capture("#{monit_command} status 2>&1")
|
49
53
|
end
|
@@ -59,4 +63,4 @@ module Luban
|
|
59
63
|
end
|
60
64
|
end
|
61
65
|
end
|
62
|
-
end
|
66
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: luban-monit
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Rubyist Chi
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-06-
|
11
|
+
date: 2016-06-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: luban
|