sensu-extensions-debug 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 95ababffc34efb7112e20594c8c7b4365407b0df
4
+ data.tar.gz: 2b3e54f4a43c8f2d13aac62a109ec1933c5cbe97
5
+ SHA512:
6
+ metadata.gz: 28a0906049b9d26b977906b6d8e2a367bd847e93904528f50813b92c497d61d6dd9b932ac2701d9996f9a69bc30a47814b22416c1636eaefa9e440eec845d0d0
7
+ data.tar.gz: 60b29f633dfe8ff4a98606272bb3fb1af3fa1d43295b6ec40f8e37a3833e2575d1b8cb84905bd2195b14371c547b9bc1677da732d319225ff7ed6edb998e480b
data/CHANGELOG.md ADDED
@@ -0,0 +1,14 @@
1
+ # Change Log
2
+
3
+ This project adheres to [Semantic Versioning](http://semver.org/).
4
+
5
+ This CHANGELOG follows the format listed at [Keep A Changelog](http://keepachangelog.com/).
6
+
7
+ ## 0.0.1 - 2016-07-27
8
+
9
+ ### Added
10
+
11
+ - Initial release.
12
+
13
+ [Unreleased]: https://github.com/sensu-extensions/sensu-extensions-template/compare/v1.0.0...HEAD
14
+ [1.0.0]: https://github.com/sensu-extensions/sensu-extensions-template/compare/v0.0.1...v1.0.0
data/LICENSE ADDED
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2016 Sensu-Extensions
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,55 @@
1
+ # Sensu::Extensions::Debug
2
+
3
+ This handler extension provides the Sensu Core built-in handler
4
+ `debug`.
5
+
6
+ This handler will return the raw event data (JSON), which will be
7
+ logged by the Sensu server process.
8
+
9
+ ## Configuration
10
+
11
+ The `debug` handler is included in every install of Sensu. To apply
12
+ the handler to a check, use the `"handler"` or `"handlers"` check
13
+ definition attribute.
14
+
15
+ For example:
16
+
17
+ ``` json
18
+ {
19
+ "checks": {
20
+ "check-http": {
21
+ "...": "...",
22
+ "handler": "debug"
23
+ }
24
+ }
25
+ }
26
+ ```
27
+
28
+ or
29
+
30
+ ``` json
31
+ {
32
+ "checks": {
33
+ "check-http": {
34
+ "...": "...",
35
+ "handlers": ["debug"]
36
+ }
37
+ }
38
+ }
39
+ ```
40
+
41
+ You can use the `debug` as the default Sensu event handler, by using a
42
+ handler set for `default`.
43
+
44
+ For example:
45
+
46
+ ``` json
47
+ {
48
+ "handlers": {
49
+ "default": {
50
+ "type": "set",
51
+ "handlers": ["debug"]
52
+ }
53
+ }
54
+ }
55
+ ```
@@ -0,0 +1,19 @@
1
+ require "sensu/extension"
2
+
3
+ module Sensu
4
+ module Extension
5
+ class Debug < Handler
6
+ def name
7
+ "debug"
8
+ end
9
+
10
+ def description
11
+ "returns raw event data"
12
+ end
13
+
14
+ def run(event)
15
+ yield event, 0
16
+ end
17
+ end
18
+ end
19
+ end
metadata ADDED
@@ -0,0 +1,131 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: sensu-extensions-debug
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ platform: ruby
6
+ authors:
7
+ - Sensu-Extensions and contributors
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2016-07-27 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: sensu-extension
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '0'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: '0'
27
+ - !ruby/object:Gem::Dependency
28
+ name: bundler
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '1.6'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '1.6'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rake
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - ">="
46
+ - !ruby/object:Gem::Version
47
+ version: '0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ">="
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
55
+ - !ruby/object:Gem::Dependency
56
+ name: rspec
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ">="
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - ">="
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
69
+ - !ruby/object:Gem::Dependency
70
+ name: sensu-logger
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - ">="
74
+ - !ruby/object:Gem::Version
75
+ version: '0'
76
+ type: :development
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - ">="
81
+ - !ruby/object:Gem::Version
82
+ version: '0'
83
+ - !ruby/object:Gem::Dependency
84
+ name: sensu-settings
85
+ requirement: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - ">="
88
+ - !ruby/object:Gem::Version
89
+ version: '0'
90
+ type: :development
91
+ prerelease: false
92
+ version_requirements: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - ">="
95
+ - !ruby/object:Gem::Version
96
+ version: '0'
97
+ description: The Sensu Core built-in debug handler
98
+ email:
99
+ - "<sensu-users@googlegroups.com>"
100
+ executables: []
101
+ extensions: []
102
+ extra_rdoc_files: []
103
+ files:
104
+ - CHANGELOG.md
105
+ - LICENSE
106
+ - README.md
107
+ - lib/sensu/extensions/debug.rb
108
+ homepage: https://github.com/sensu-extensions/sensu-extensions-debug
109
+ licenses: []
110
+ metadata: {}
111
+ post_install_message:
112
+ rdoc_options: []
113
+ require_paths:
114
+ - lib
115
+ required_ruby_version: !ruby/object:Gem::Requirement
116
+ requirements:
117
+ - - ">="
118
+ - !ruby/object:Gem::Version
119
+ version: '0'
120
+ required_rubygems_version: !ruby/object:Gem::Requirement
121
+ requirements:
122
+ - - ">="
123
+ - !ruby/object:Gem::Version
124
+ version: '0'
125
+ requirements: []
126
+ rubyforge_project:
127
+ rubygems_version: 2.6.3
128
+ signing_key:
129
+ specification_version: 4
130
+ summary: The Sensu Core built-in debug handler
131
+ test_files: []