turbot/alicloud

steampipe plugin install alicloudsteampipe plugin install alicloud

Table: alicloud_vpc_nat_gateway

NAT gateways are enterprise-class gateways that provide the Source Network Address Translation (SNAT) and Destination Network Address Translation (DNAT) features. Each NAT gateway provides a throughput capacity of up to 10 Gbit/s. NAT gateways also support cross-zone disaster recovery.

Examples

Basic info

select
name,
nat_gateway_id,
vpc_id nat_type,
status,
description,
billing_method,
region,
account_id
from
alicloud_vpc_nat_gateway;

List IP address details for NAT gateways

select
nat_gateway_id,
address ->> 'IpAddress' as ip_address,
address ->> 'AllocationId' as allocation_id
from
alicloud_vpc_nat_gateway,
jsonb_array_elements(ip_lists) as address;

List private network info for NAT gateways

select
name,
nat_gateway_id,
nat_gateway_private_info ->> 'EniInstanceId' as eni_instance_id,
nat_gateway_private_info ->> 'IzNo' as nat_gateway_zone_id,
nat_gateway_private_info ->> 'MaxBandwidth' as max_bandwidth,
nat_gateway_private_info ->> 'PrivateIpAddress' as private_ip_address,
nat_gateway_private_info ->> 'VswitchId' as vswitch_id
from
alicloud_vpc_nat_gateway;

List NAT gateways that have traffic monitoring disabled

select
name,
nat_gateway_id,
ecs_metric_enabled
from
alicloud_vpc_nat_gateway
where
not ecs_metric_enabled;

List NAT gateways that have deletion protection disabled

select
name,
nat_gateway_id,
deletion_protection
from
alicloud_vpc_nat_gateway
where
not deletion_protection;

Count of NAT gateways per VPC ID

select
vpc_id,
count(*) as nat_gateway_count
from
alicloud_vpc_nat_gateway
group by
vpc_id;

Control examples

.inspect alicloud_vpc_nat_gateway

Aliclod VPC NAT Gateway

NameTypeDescription
account_idtextThe Alicloud Account ID in which the resource is located.
akasjsonbArray of globally unique identifier strings (also known as) for the resource.
auto_paybooleanIndicates whether auto pay is enabled.
billing_methodtextThe billing method of the NAT gateway.
business_statustextThe status of the NAT gateway.
creation_timetimestamp without time zoneThe time when the NAT gateway was created.
deletion_protectionbooleanIndicates whether deletion protection is enabled.
descriptiontextThe description of the NAT gateway.
ecs_metric_enabledbooleanIndicates whether the traffic monitoring feature is enabled.
expired_imetimestamp without time zoneThe time when the NAT gateway expires.
forward_table_idsjsonbThe ID of the Destination Network Address Translation (DNAT) table.
internet_charge_typetextThe billing method of the NAT gateway.
ip_listsjsonbThe elastic IP address (EIP) that is associated with the NAT gateway.
nametextThe name of the NAT gateway.
nat_gateway_idtextThe ID of the NAT gateway.
nat_gateway_private_infojsonbThe information of the virtual private cloud (VPC) to which the enhanced NAT gateway belongs.
nat_typetextThe type of the NAT gateway. Valid values: 'Normal' and 'Enhanced'.
regiontextThe Alicloud region in which the resource is located.
resource_group_idtextThe ID of the resource group.
snat_table_idsjsonbThe ID of the SNAT table for the NAT gateway.
spectextThe size of the NAT gateway.
statustextThe state of the NAT gateway.
titletextTitle of the resource.
vpc_idtextThe ID of the virtual private cloud (VPC) to which the NAT gateway belongs.