sensu-plugins-opsgenie 4.1.0 → 4.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +9 -1
- data/README.md +3 -3
- data/bin/handler-opsgenie.rb +10 -1
- data/lib/sensu-plugins-opsgenie/version.rb +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ecec93fcdad20ded690183b46d1190544be11d1a4d25a0be3ad2d43f866390a7
|
4
|
+
data.tar.gz: 953b9126df12d4d1fd24601cadfd28714b7431988e4ed4c826f9da0955374371
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8e046da8e46bed5dc66a7e66296c3822dcce92642993e916d788a02bbe3e77b206a7558932bf9ba679396202bedc99396286b53e21583cb3e2233fc6b0dc848e
|
7
|
+
data.tar.gz: 266c2bb8b84094163069c5ae9d50fe4cb4f528b29e054ce42a066259beadd67a547b3ce77fba812de2a4fe1c9feae44b00a31152d7589c2d8e278edfd93ece21
|
data/CHANGELOG.md
CHANGED
@@ -5,6 +5,13 @@ This CHANGELOG follows the format listed [here](https://github.com/sensu-plugins
|
|
5
5
|
|
6
6
|
## [Unreleased]
|
7
7
|
|
8
|
+
## [4.1.1] - 2018-01-16
|
9
|
+
### Security
|
10
|
+
- updated rubocop dependency to `~> 0.51.0` per: https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2017-8418. (@majormoses)
|
11
|
+
|
12
|
+
### Changed
|
13
|
+
- appease the cops, left TODO for investigating `URI.escape` alternatives (@majormoses)
|
14
|
+
|
8
15
|
## [4.1.0] 2018-01-14
|
9
16
|
### Added
|
10
17
|
- Added possibility to specify custom alias for event ID, this acts in a similar way to proxy/JIT clients to dedupe alerts (@Castaglia)
|
@@ -85,7 +92,8 @@ This CHANGELOG follows the format listed [here](https://github.com/sensu-plugins
|
|
85
92
|
- initial release
|
86
93
|
- Fixed json configuration load
|
87
94
|
|
88
|
-
[Unreleased]: https://github.com/sensu-plugins/sensu-plugins-opsgenie/compare/4.1.
|
95
|
+
[Unreleased]: https://github.com/sensu-plugins/sensu-plugins-opsgenie/compare/4.1.1...HEAD
|
96
|
+
[4.1.1]: https://github.com/sensu-plugins/sensu-plugins-opsgenie/compare/4.1.0...4.1.1
|
89
97
|
[4.1.0]: https://github.com/sensu-plugins/sensu-plugins-opsgenie/compare/4.0.1...4.1.0
|
90
98
|
[4.0.1]: https://github.com/sensu-plugins/sensu-plugins-opsgenie/compare/4.0.0...4.0.1
|
91
99
|
[4.0.0]: https://github.com/sensu-plugins/sensu-plugins-opsgenie/compare/3.1.0...4.0.0
|
data/README.md
CHANGED
@@ -33,7 +33,7 @@
|
|
33
33
|
[Installation and Setup](http://sensu-plugins.io/docs/installation_instructions.html)
|
34
34
|
|
35
35
|
## Configuration
|
36
|
-
To get this to work you need to specify a few different things. For a list of fields that are required/available look at the [sensu documentation](https://sensuapp.org/docs/0.25/enterprise/integrations/opsgenie.html). These files need to be on the server and the client boxes. Once there restart sensu-server and sensu-api.
|
36
|
+
To get this to work you need to specify a few different things. For a list of fields that are required/available look at the [sensu documentation](https://sensuapp.org/docs/0.25/enterprise/integrations/opsgenie.html). These files need to be on the server and the client boxes. Once there restart sensu-server and sensu-api.
|
37
37
|
|
38
38
|
- declare this as a handler: `/etc/sensu/conf.d/handler_opsgenie.json`
|
39
39
|
``` json
|
@@ -47,7 +47,7 @@ To get this to work you need to specify a few different things. For a list of fi
|
|
47
47
|
"opsgenie": {
|
48
48
|
"customerKey": "YOUR-KEY-HERE"
|
49
49
|
}
|
50
|
-
}
|
50
|
+
}
|
51
51
|
```
|
52
52
|
|
53
53
|
- add it to the check: `/etc/sensu/conf.d/check_xxx.json`
|
@@ -63,7 +63,7 @@ To get this to work you need to specify a few different things. For a list of fi
|
|
63
63
|
}
|
64
64
|
}
|
65
65
|
```
|
66
|
-
|
66
|
+
|
67
67
|
- optionally add it to the default handler: `/etc/sensu/conf.d/default_handler.json`
|
68
68
|
``` json
|
69
69
|
{
|
data/bin/handler-opsgenie.rb
CHANGED
@@ -134,7 +134,16 @@ class Opsgenie < Sensu::Handler
|
|
134
134
|
params['source'] = json_config['source'] if json_config['source']
|
135
135
|
|
136
136
|
encoded_alias = URI.escape(params[:alias])
|
137
|
-
|
137
|
+
# TODO: come back and asses if this logic is correct, I left it functionally
|
138
|
+
# as it was originally written but I suspect we should have at least three
|
139
|
+
# cases to check: create, close, and else for catching errors but I don't
|
140
|
+
# really know the opsgenie API and am not terribly motivated to look into it
|
141
|
+
# right now.
|
142
|
+
uripath = if action == :create
|
143
|
+
''
|
144
|
+
else
|
145
|
+
"#{encoded_alias}/close?identifierType=alias"
|
146
|
+
end
|
138
147
|
uri = URI.parse("#{OPSGENIE_URL}/#{uripath}")
|
139
148
|
http = Net::HTTP.new(uri.host, uri.port)
|
140
149
|
http.use_ssl = true
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sensu-plugins-opsgenie
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.1.
|
4
|
+
version: 4.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sensu-Plugins and contributors
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-01-
|
11
|
+
date: 2018-01-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: sensu-plugin
|
@@ -176,14 +176,14 @@ dependencies:
|
|
176
176
|
requirements:
|
177
177
|
- - "~>"
|
178
178
|
- !ruby/object:Gem::Version
|
179
|
-
version: 0.
|
179
|
+
version: 0.51.0
|
180
180
|
type: :development
|
181
181
|
prerelease: false
|
182
182
|
version_requirements: !ruby/object:Gem::Requirement
|
183
183
|
requirements:
|
184
184
|
- - "~>"
|
185
185
|
- !ruby/object:Gem::Version
|
186
|
-
version: 0.
|
186
|
+
version: 0.51.0
|
187
187
|
- !ruby/object:Gem::Dependency
|
188
188
|
name: serverspec
|
189
189
|
requirement: !ruby/object:Gem::Requirement
|