Method: Awspec::Helper::Finder::Ec2#find_tgw_attachments_by_tgw_id

Defined in:
lib/awspec/helper/finder/ec2.rb

#find_tgw_attachments_by_tgw_id(tgw_id) ⇒ Object



227
228
229
230
231
232
233
234
# File 'lib/awspec/helper/finder/ec2.rb', line 227

def find_tgw_attachments_by_tgw_id(tgw_id)
  res = ec2_client.describe_transit_gateway_attachments({
                                                          filters: [
                                                            { name: 'transit-gateway-id', values: [tgw_id] }
                                                          ]
                                                        })
  res.transit_gateway_attachments
end