sensu 0.25.3 → 0.25.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +7 -0
- data/lib/sensu/#test.json# +37 -0
- data/lib/sensu/api/process.rb +18 -8
- data/lib/sensu/constants.rb +1 -1
- metadata +4 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 395c016d81d285d4638a986ed2e74f3a57eeee12
|
4
|
+
data.tar.gz: b1910e9c168985868d21960ece8dc89db4827814
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d019339a148fb8ddc6f5bed53c39229ef5b2007ce80f8e20c63fcd26ca246180cd52fbcefe19dc1b8526fce5284ef80d79b5e5caede41af04e4d161eece9daab
|
7
|
+
data.tar.gz: f33ded0aae861eedefcb2260a2d0c8fca7356511db8f101ddb4d038099ddbb929b8537e703a1be9d460abf2bb6234ce552c7ef6ad4929a7f7777da842239ff07
|
data/CHANGELOG.md
CHANGED
@@ -0,0 +1,37 @@
|
|
1
|
+
{
|
2
|
+
|
3
|
+
"checks": {
|
4
|
+
|
5
|
+
"check_procs_slapd": {
|
6
|
+
|
7
|
+
"command": "/usr/local/nagios/libexec/check_procs -c 1:4 -w 1:4 -a libexec/slapd",
|
8
|
+
|
9
|
+
"subscribers": ["EBB_CKPRC_SLAPD", "EBB"],
|
10
|
+
|
11
|
+
"interval": 60
|
12
|
+
|
13
|
+
},
|
14
|
+
|
15
|
+
"check_procs_syslog-ng": {
|
16
|
+
|
17
|
+
"command": "/usr/local/nagios/libexec/check_procs -w 1:4 -c 1:4 -a syslog-ng",
|
18
|
+
|
19
|
+
"subscribers": ["EBB_CKPRC_SYSLOGNG", "EBB"],
|
20
|
+
|
21
|
+
"interval": 60
|
22
|
+
|
23
|
+
},
|
24
|
+
|
25
|
+
"check_procs_total_procs": {
|
26
|
+
|
27
|
+
"command": "/usr/local/nagios/libexec/check_procs -w 150 -c 250",
|
28
|
+
|
29
|
+
"subscribers": ["EBB_CKPRC_TOTAL", "EBB"],
|
30
|
+
|
31
|
+
"interval": 60
|
32
|
+
|
33
|
+
}
|
34
|
+
|
35
|
+
}
|
36
|
+
|
37
|
+
}
|
data/lib/sensu/api/process.rb
CHANGED
@@ -15,13 +15,23 @@ module Sensu
|
|
15
15
|
def self.run(options={})
|
16
16
|
api = self.new(options)
|
17
17
|
EM::run do
|
18
|
-
api.setup_redis
|
19
|
-
api.setup_transport
|
20
18
|
api.start
|
21
19
|
api.setup_signal_traps
|
22
20
|
end
|
23
21
|
end
|
24
22
|
|
23
|
+
# Setup connections to redis and transport
|
24
|
+
#
|
25
|
+
# @yield [Object] a callback/block to be called after redis and
|
26
|
+
# transport connections have been established.
|
27
|
+
def setup_connections
|
28
|
+
setup_redis do |redis|
|
29
|
+
setup_transport do |transport|
|
30
|
+
yield if block_given?
|
31
|
+
end
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
25
35
|
# Start the API HTTP server. This method sets `@http_server`.
|
26
36
|
#
|
27
37
|
# @param bind [String] address to listen on.
|
@@ -46,7 +56,10 @@ module Sensu
|
|
46
56
|
api = @settings[:api] || {}
|
47
57
|
bind = api[:bind] || "0.0.0.0"
|
48
58
|
port = api[:port] || 4567
|
49
|
-
|
59
|
+
setup_connections do
|
60
|
+
start_http_server(bind, port)
|
61
|
+
yield if block_given?
|
62
|
+
end
|
50
63
|
super
|
51
64
|
end
|
52
65
|
|
@@ -67,11 +80,8 @@ module Sensu
|
|
67
80
|
# @param options [Hash]
|
68
81
|
def self.test(options={})
|
69
82
|
api = self.new(options)
|
70
|
-
api.
|
71
|
-
|
72
|
-
api.start
|
73
|
-
yield
|
74
|
-
end
|
83
|
+
api.start do
|
84
|
+
yield
|
75
85
|
end
|
76
86
|
end
|
77
87
|
end
|
data/lib/sensu/constants.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sensu
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.25.
|
4
|
+
version: 0.25.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sean Porter
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: exe
|
11
11
|
cert_chain: []
|
12
|
-
date: 2016-06-
|
12
|
+
date: 2016-06-21 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: eventmachine
|
@@ -227,6 +227,7 @@ files:
|
|
227
227
|
- exe/sensu-install
|
228
228
|
- exe/sensu-server
|
229
229
|
- lib/sensu.rb
|
230
|
+
- lib/sensu/#test.json#
|
230
231
|
- lib/sensu/api/http_handler.rb
|
231
232
|
- lib/sensu/api/process.rb
|
232
233
|
- lib/sensu/api/routes.rb
|
@@ -279,7 +280,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
279
280
|
version: '0'
|
280
281
|
requirements: []
|
281
282
|
rubyforge_project:
|
282
|
-
rubygems_version: 2.6.
|
283
|
+
rubygems_version: 2.6.4
|
283
284
|
signing_key:
|
284
285
|
specification_version: 4
|
285
286
|
summary: A monitoring framework
|