bin/check-elb-nodes.rb in sensu-plugins-aws-0.0.1.alpha.2 vs bin/check-elb-nodes.rb in sensu-plugins-aws-0.0.1
- old
+ new
@@ -29,11 +29,10 @@
# Copyright (c) 2013, Justin Lambert <jlambert@letsevenup.com>
# Released under the same terms as Sensu (the MIT license); see LICENSE
# for details.
#
-require 'rubygems' if RUBY_VERSION < '1.9.0'
require 'sensu-plugin/check/cli'
require 'aws-sdk'
class CheckELBNodes < Sensu::Plugin::Check::CLI
option :aws_access_key,
@@ -92,10 +91,10 @@
if config[:aws_access_key] && config[:aws_secret_access_key]
hash.update region: config[:aws_region]
hash
end
- def run
+ def run # rubocop:disable all
AWS.start_memoizing
elb = AWS::ELB.new aws_config
begin
instances = elb.load_balancers[config[:load_balancer]].instances.health