Sha256: 1ee042a60057b9d53f2230f88752267fd94f50a5ca4e7fa7cd5a9f1cc8e89eec
Contents?: true
Size: 638 Bytes
Versions: 12
Compression:
Stored size: 638 Bytes
Contents
# frozen_string_literal: true module Awspec::Type class AlbTargetGroup < ResourceBase def resource_via_client @resource_via_client ||= find_alb_target_group(@display_name) end def id @id ||= resource_via_client.target_group_name if resource_via_client end def has_ec2?(id) ec2 = find_ec2(id) return nil unless ec2 descriptions = elbv2_client.describe_target_health( target_group_arn: resource_via_client.target_group_arn ).target_health_descriptions descriptions.find do |description| description.target.id == ec2.instance_id end end end end
Version data entries
12 entries across 12 versions & 1 rubygems