sensu-plugins-mailer 1.2.0 → 2.0.0

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: e9aa2a9997cccbcdd4266654fbd3882bd2002678
4
- data.tar.gz: 35e033dc524dfebf003249436810f67a4a0c4c27
3
+ metadata.gz: 511b8ca719d1df99caab5a4c0201ca72f4e165ef
4
+ data.tar.gz: 5e3fdaaf730021fc4868bcf08591fd3364ea166d
5
5
  SHA512:
6
- metadata.gz: f3369051b649641a7cf308f683847b14928f07a570980a301ad7c06e6094ede2ef4ff63074e721ef970611c2d4b79c23a48c5d3536c43064e7fbe7288005e761
7
- data.tar.gz: 80574d190775484e384e342923eb97bc2b8d3632744890f58991aef3edff573aa852efb6c87882cecbc152670440f9aca4153a7fefcc334a528c96a9c2eccc1f
6
+ metadata.gz: b6fa085f83410b75bbeb79fb3d64783ead7458cfefaf30d04837c3c67ee6579c22a9e7b8aefe86f68397ceabe4e3322061bc4f75ccbe9ffe760eccac1d2822c7
7
+ data.tar.gz: 859e4f9c3891d272b4c4d981e893314d42055f7d181e7bac605609385bd327924c977b9c6b0e52ca8648885cd90d823daa2bc76e3b0c1dd5cd40a5aa11bf947b
@@ -1,10 +1,22 @@
1
- #Change Log
1
+ # Change Log
2
2
  This project adheres to [Semantic Versioning](http://semver.org/).
3
3
 
4
- This CHANGELOG follows the format listed at [Keep A Changelog](http://keepachangelog.com/)
4
+ This CHANGELOG follows the format listed [here](https://github.com/sensu-plugins/community/blob/master/HOW_WE_CHANGELOG.md)
5
5
 
6
6
  ## [Unreleased]
7
7
 
8
+ ## [2.0.0] - 2017-10-21
9
+ ### Breaking Change
10
+ - handler-mailer.rb: emit an `unknown` with a helpful message when trying to configure `settings['contact']` with multiple objects. This helps avoid confusion over using `contact` when you meant `contacts`. (@majormoses)
11
+
12
+ ### Added
13
+ - ruby 2.4 testing in travis. (@majormoses)
14
+ - handler-mailer.rb: added default key in description (@arthurlogilab)
15
+
16
+ ### Fixed
17
+ - PR template spell "Compatibility" correctly (@majormoses)
18
+ - update changelog guideline location (@majormoses)
19
+
8
20
  ## [1.2.0] - 2017-06-24
9
21
  ### Added
10
22
  - handler-mailer.rb: add contact routing like Sensu Enterprise works (@stevenviola)
@@ -90,6 +102,7 @@ This CHANGELOG follows the format listed at [Keep A Changelog](http://keepachang
90
102
  - initial release
91
103
 
92
104
  [Unreleased]: https://github.com/sensu-plugins/sensu-plugins-mailer/compare/1.2.0...HEAD
105
+ [2.0.0]: https://github.com/sensu-plugins/sensu-plugins-mailer/compare/1.2.0...2.0.0
93
106
  [1.2.0]: https://github.com/sensu-plugins/sensu-plugins-mailer/compare/1.1.0...1.2.0
94
107
  [1.1.0]: https://github.com/sensu-plugins/sensu-plugins-mailer/compare/1.0.0...1.1.0
95
108
  [1.0.0]: https://github.com/sensu-plugins/sensu-plugins-mailer/compare/0.3.1...1.0.0
@@ -36,7 +36,7 @@ end
36
36
 
37
37
  class Mailer < Sensu::Handler
38
38
  option :json_config_name,
39
- description: 'Name of the JSON Configuration block in Sensu',
39
+ description: 'Name of the JSON Configuration block in Sensu (default: mailer)',
40
40
  short: '-j JsonConfig',
41
41
  long: '--json_config JsonConfig',
42
42
  required: false,
@@ -145,7 +145,13 @@ class Mailer < Sensu::Handler
145
145
  end
146
146
  end
147
147
  end
148
- if settings.key?('contacts')
148
+ if settings.key?('contact') && settings['contact'].is_a?(Array)
149
+ msg = "you passed #{settings['contact']} which is meant to be a string, "
150
+ msg += 'if you need more than one contact you can use `contacts` to '
151
+ msg += 'configure multiple recipients'
152
+ p msg
153
+ exit 3 # unknown
154
+ elsif settings.key?('contacts')
149
155
  all_contacts = []
150
156
  %w(check client).each do |field|
151
157
  if @event[field].key?('contact')
@@ -1,7 +1,7 @@
1
1
  module SensuPluginsMailer
2
2
  module Version
3
- MAJOR = 1
4
- MINOR = 2
3
+ MAJOR = 2
4
+ MINOR = 0
5
5
  PATCH = 0
6
6
 
7
7
  VER_STRING = [MAJOR, MINOR, PATCH].compact.join('.')
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sensu-plugins-mailer
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.0
4
+ version: 2.0.0
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: 2017-06-24 00:00:00.000000000 Z
11
+ date: 2017-10-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-ses
@@ -263,7 +263,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
263
263
  version: '0'
264
264
  requirements: []
265
265
  rubyforge_project:
266
- rubygems_version: 2.4.5
266
+ rubygems_version: 2.6.14
267
267
  signing_key:
268
268
  specification_version: 4
269
269
  summary: Sensu plugins for mailer