Sha256: 3cc2e9142d63b58463a372206a6a1d2487a66b2147cd5d0e3994d8170c8e2ba4

Contents?: true

Size: 448 Bytes

Versions: 20

Compression:

Stored size: 448 Bytes

Contents

module Awspec::Helper
  module Finder
    module Alb
      def find_alb(id)
        res = elbv2_client.describe_load_balancers({ names: [id] })
        res.load_balancers.single_resource(id)
      rescue
        return nil
      end

      def select_alb_by_vpc_id(vpc_id)
        res = elbv2_client.describe_load_balancers
        res.load_balancer_descriptions.select do |lb|
          lb.vpc_id == vpc_id
        end
      end
    end
  end
end

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
awspec-0.73.2 lib/awspec/helper/finder/alb.rb
awspec-0.73.1 lib/awspec/helper/finder/alb.rb
awspec-0.73.0 lib/awspec/helper/finder/alb.rb
awspec-0.72.0 lib/awspec/helper/finder/alb.rb
awspec-0.71.0 lib/awspec/helper/finder/alb.rb
awspec-0.70.0 lib/awspec/helper/finder/alb.rb
awspec-0.69.1 lib/awspec/helper/finder/alb.rb
awspec-0.69.0 lib/awspec/helper/finder/alb.rb
awspec-0.68.0 lib/awspec/helper/finder/alb.rb
awspec-0.67.1 lib/awspec/helper/finder/alb.rb
awspec-0.67.0 lib/awspec/helper/finder/alb.rb
awspec-0.66.2 lib/awspec/helper/finder/alb.rb
awspec-0.66.1 lib/awspec/helper/finder/alb.rb
awspec-0.66.0 lib/awspec/helper/finder/alb.rb
awspec-0.65.2 lib/awspec/helper/finder/alb.rb
awspec-0.65.1 lib/awspec/helper/finder/alb.rb
awspec-0.65.0 lib/awspec/helper/finder/alb.rb
awspec-0.64.0 lib/awspec/helper/finder/alb.rb
awspec-0.63.1 lib/awspec/helper/finder/alb.rb
awspec-0.63.0 lib/awspec/helper/finder/alb.rb