sensu-settings 9.1.2 → 9.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: abf1a2331279c4c3f0359d9616cae1507f543a39
4
- data.tar.gz: bc27754d38ea174528c251d9ff15557ae6898020
3
+ metadata.gz: e1b81eae55c8690a5b2ac6e492b2e5bdc1e1dea5
4
+ data.tar.gz: 7703b6e12854c67d93535693003696529694d95a
5
5
  SHA512:
6
- metadata.gz: 8a185d29af80da7d3e325a46902df2fcad06464d02c5bab6b6f2cdf484d4b8b8b4d2593f6e4e65f877f994ee3ca7a09020a9adba12c12e7e75524b471b0e1e09
7
- data.tar.gz: e9ffe6d03e428179c736514b1fba3f26d5465ba69e7cdff53d480ee5e4cb98a207d7f3b5d4b8a887e9447dba0e846755e353a94ca17f53547a08985d40bf0d86
6
+ metadata.gz: 5b6df1b910f9f61a7ba0f97cd4cbe7ae87e38421af01d709c5e7ea7cec781e93028d5ef3074288913932bcb4840a38b1061d54104f8232f4d7b101c4ab992799
7
+ data.tar.gz: f46512869ee3898cbf1b4a816c3d0c12f6a6d67ed6b752e005569d104688a4a66da26f18d51fc3891e3eb1c9ee5205a94f508e2fd231d3eaa8a3bec5f49ada34
@@ -51,6 +51,7 @@ module Sensu
51
51
  # @return [Hash] settings.
52
52
  def default_settings
53
53
  default = {
54
+ :client => {},
54
55
  :sensu => {
55
56
  :spawn => {
56
57
  :limit => 12
@@ -174,7 +175,6 @@ module Sensu
174
175
  # * Ensuring client subscriptions include a single subscription based on the
175
176
  # client name, e.g "client:i-424242".
176
177
  def load_client_overrides
177
- @settings[:client] ||= {}
178
178
  @settings[:client][:subscriptions] ||= []
179
179
  @settings[:client][:subscriptions] << "client:#{@settings[:client][:name]}"
180
180
  @settings[:client][:subscriptions].uniq!
@@ -310,7 +310,7 @@ module Sensu
310
310
  def load_client_env
311
311
  @settings[:client][:name] = ENV["SENSU_CLIENT_NAME"] if ENV["SENSU_CLIENT_NAME"]
312
312
  @settings[:client][:address] = ENV["SENSU_CLIENT_ADDRESS"] if ENV["SENSU_CLIENT_ADDRESS"]
313
- @settings[:client][:subscriptions] = ENV.fetch("SENSU_CLIENT_SUBSCRIPTIONS", "").split(",")
313
+ @settings[:client][:subscriptions] = ENV["SENSU_CLIENT_SUBSCRIPTIONS"].split(",") if ENV["SENSU_CLIENT_SUBSCRIPTIONS"]
314
314
  if ENV.keys.any? {|k| k =~ /^SENSU_CLIENT/}
315
315
  warning("using sensu client environment variables", :client => @settings[:client])
316
316
  end
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |spec|
4
4
  spec.name = "sensu-settings"
5
- spec.version = "9.1.2"
5
+ spec.version = "9.2.0"
6
6
  spec.authors = ["Sean Porter"]
7
7
  spec.email = ["portertech@gmail.com"]
8
8
  spec.summary = "The Sensu settings library, loader and validator"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sensu-settings
3
3
  version: !ruby/object:Gem::Version
4
- version: 9.1.2
4
+ version: 9.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sean Porter
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-09-12 00:00:00.000000000 Z
11
+ date: 2016-09-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: sensu-json
@@ -126,7 +126,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
126
126
  version: '0'
127
127
  requirements: []
128
128
  rubyforge_project:
129
- rubygems_version: 2.6.3
129
+ rubygems_version: 2.6.6
130
130
  signing_key:
131
131
  specification_version: 4
132
132
  summary: The Sensu settings library, loader and validator