import * as core from "@terrascript/core"; export interface SubnetArgs extends core.ResourceArgs { /** * (Optional) Specify true to indicate */ assignIpv6AddressOnCreation?: boolean | core.BooleanOut; /** * (Optional) AZ for the subnet. */ availabilityZone?: string | core.StringOut; /** * (Optional) AZ ID of the subnet. This argument is not supported in all regions or partitions. If nece * ssary, use `availability_zone` instead. */ availabilityZoneId?: string | core.StringOut; /** * (Optional) The IPv4 CIDR block for the subnet. */ cidrBlock?: string | core.StringOut; /** * (Optional) The customer owned IPv4 address pool. Typically used with the `map_customer_owned_ip_on_l * aunch` argument. The `outpost_arn` argument must be specified when configured. */ customerOwnedIpv4Pool?: string | core.StringOut; /** * (Optional) Indicates whether DNS queries made to the Amazon-provided DNS Resolver in this subnet sho * uld return synthetic IPv6 addresses for IPv4-only destinations. Default: `false`. */ enableDns64?: boolean | core.BooleanOut; /** * (Optional) Indicates whether to respond to DNS queries for instance hostnames with DNS A records. De * fault: `false`. */ enableResourceNameDnsARecordOnLaunch?: boolean | core.BooleanOut; /** * (Optional) Indicates whether to respond to DNS queries for instance hostnames with DNS AAAA records. * Default: `false`. */ enableResourceNameDnsAaaaRecordOnLaunch?: boolean | core.BooleanOut; /** * (Optional) The IPv6 network range for the subnet, */ ipv6CidrBlock?: string | core.StringOut; /** * (Optional) Indicates whether to create an IPv6-only subnet. Default: `false`. */ ipv6Native?: boolean | core.BooleanOut; /** * (Optional) Specify `true` to indicate that network interfaces created in the subnet should be assig * ned a customer owned IP address. The `customer_owned_ipv4_pool` and `outpost_arn` arguments must be * specified when set to `true`. Default is `false`. */ mapCustomerOwnedIpOnLaunch?: boolean | core.BooleanOut; /** * (Optional) Specify true to indicate */ mapPublicIpOnLaunch?: boolean | core.BooleanOut; /** * (Optional) The Amazon Resource Name (ARN) of the Outpost. */ outpostArn?: string | core.StringOut; /** * (Optional) The type of hostnames to assign to instances in the subnet at launch. For IPv6-only subne * ts, an instance DNS name must be based on the instance ID. For dual-stack and IPv4-only subnets, you * can specify whether DNS names use the instance IPv4 address or the instance ID. Valid values: `ip-n * ame`, `resource-name`. */ privateDnsHostnameTypeOnLaunch?: string | core.StringOut; /** * (Optional) A map of tags to assign to the resource. If configured with a provider [`default_tags` co * nfiguration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags-co * nfiguration-block) present, tags with matching keys will overwrite those defined at the provider-lev * el. */ tags?: core.Map | core.MapOut; /** * A map of tags assigned to the resource, including those inherited from the provider [`default_tags` * configuration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags- * configuration-block). */ tagsAll?: core.Map | core.MapOut; /** * (Required) The VPC ID. */ vpcId: string | core.StringOut; } export class Subnet extends core.Resource { /** * The ARN of the subnet. */ @core.attr(String, { computed: true }) public arn!: string | core.StringOut; /** * (Optional) Specify true to indicate */ @core.attr(Boolean) public assignIpv6AddressOnCreation?: boolean | core.BooleanOut; /** * (Optional) AZ for the subnet. */ @core.attr(String, { computed: true }) public availabilityZone?: string | core.StringOut; /** * (Optional) AZ ID of the subnet. This argument is not supported in all regions or partitions. If nece * ssary, use `availability_zone` instead. */ @core.attr(String, { computed: true }) public availabilityZoneId?: string | core.StringOut; /** * (Optional) The IPv4 CIDR block for the subnet. */ @core.attr(String) public cidrBlock?: string | core.StringOut; /** * (Optional) The customer owned IPv4 address pool. Typically used with the `map_customer_owned_ip_on_l * aunch` argument. The `outpost_arn` argument must be specified when configured. */ @core.attr(String) public customerOwnedIpv4Pool?: string | core.StringOut; /** * (Optional) Indicates whether DNS queries made to the Amazon-provided DNS Resolver in this subnet sho * uld return synthetic IPv6 addresses for IPv4-only destinations. Default: `false`. */ @core.attr(Boolean) public enableDns64?: boolean | core.BooleanOut; /** * (Optional) Indicates whether to respond to DNS queries for instance hostnames with DNS A records. De * fault: `false`. */ @core.attr(Boolean) public enableResourceNameDnsARecordOnLaunch?: boolean | core.BooleanOut; /** * (Optional) Indicates whether to respond to DNS queries for instance hostnames with DNS AAAA records. * Default: `false`. */ @core.attr(Boolean) public enableResourceNameDnsAaaaRecordOnLaunch?: boolean | core.BooleanOut; /** * The ID of the subnet */ @core.attr(String, { computed: true }) public id!: string | core.StringOut; /** * (Optional) The IPv6 network range for the subnet, */ @core.attr(String) public ipv6CidrBlock?: string | core.StringOut; /** * The association ID for the IPv6 CIDR block. */ @core.attr(String, { computed: true }) public ipv6CidrBlockAssociationId!: string | core.StringOut; /** * (Optional) Indicates whether to create an IPv6-only subnet. Default: `false`. */ @core.attr(Boolean) public ipv6Native?: boolean | core.BooleanOut; /** * (Optional) Specify `true` to indicate that network interfaces created in the subnet should be assig * ned a customer owned IP address. The `customer_owned_ipv4_pool` and `outpost_arn` arguments must be * specified when set to `true`. Default is `false`. */ @core.attr(Boolean) public mapCustomerOwnedIpOnLaunch?: boolean | core.BooleanOut; /** * (Optional) Specify true to indicate */ @core.attr(Boolean) public mapPublicIpOnLaunch?: boolean | core.BooleanOut; /** * (Optional) The Amazon Resource Name (ARN) of the Outpost. */ @core.attr(String) public outpostArn?: string | core.StringOut; /** * The ID of the AWS account that owns the subnet. */ @core.attr(String, { computed: true }) public ownerId!: string | core.StringOut; /** * (Optional) The type of hostnames to assign to instances in the subnet at launch. For IPv6-only subne * ts, an instance DNS name must be based on the instance ID. For dual-stack and IPv4-only subnets, you * can specify whether DNS names use the instance IPv4 address or the instance ID. Valid values: `ip-n * ame`, `resource-name`. */ @core.attr(String, { computed: true }) public privateDnsHostnameTypeOnLaunch?: string | core.StringOut; /** * (Optional) A map of tags to assign to the resource. If configured with a provider [`default_tags` co * nfiguration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags-co * nfiguration-block) present, tags with matching keys will overwrite those defined at the provider-lev * el. */ @core.attr(String, { kind: "map" }) public tags?: core.Map | core.MapOut; /** * A map of tags assigned to the resource, including those inherited from the provider [`default_tags` * configuration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags- * configuration-block). */ @core.attr(String, { computed: true, kind: "map" }) public tagsAll?: core.Map | core.MapOut; /** * (Required) The VPC ID. */ @core.attr(String) public vpcId!: string | core.StringOut; constructor(name: string, args?: SubnetArgs) { super(name, "aws_subnet", args); } public override getNamespace(): string { return "aws_vpc"; } }