subnets_list_only
Lists subnets in a region or regions, for all properties use subnets
Overview
| Name | subnets_list_only |
| Type | Resource |
| Description | Specifies a subnet for the specified VPC. For an IPv4 only subnet, specify an IPv4 CIDR block. If the VPC has an IPv6 CIDR block, you can create an IPv6 only subnet or a dual stack subnet instead. For an IPv6 only subnet, specify an IPv6 CIDR block. For a dual stack subnet, specify both an IPv4 CIDR block and an IPv6 CIDR block. For more information, see [Subnets for your VPC](https://docs.aws.amazon.com/vpc/latest/userguide/configure-subnets.html) in the Amazon VPC User Guide. |
| Id | aws.ec2.subnets_list_only |
Fields
| Name | Datatype | Description |
|---|---|---|
subnet_id | string | |
region | string | AWS region. |
Methods
| Name | Accessible by | Required Params |
|---|---|---|
list_resources | SELECT | region |
SELECT examples
Lists all subnets in a region.
SELECT
region,
subnet_id
FROM aws.ec2.subnets_list_only
WHERE region = 'us-east-1';
Permissions
For permissions required to operate on the subnets_list_only resource, see subnets