AWS::EC2::SubnetCidrBlock - AWS CloudFormation

AWS::EC2::SubnetCidrBlock

Associates a CIDR block with your subnet. You can associate a single IPv6 CIDR block with your subnet. An IPv6 CIDR block must have a prefix length of /64.

Syntax

To declare this entity in your AWS CloudFormation template, use the following syntax:

JSON

{ "Type" : "AWS::EC2::SubnetCidrBlock", "Properties" : { "Ipv6CidrBlock" : String, "SubnetId" : String } }

YAML

Type: AWS::EC2::SubnetCidrBlock Properties: Ipv6CidrBlock: String SubnetId: String

Properties

Ipv6CidrBlock

The IPv6 network range for the subnet, in CIDR notation. The subnet size must use a /64 prefix length.

This parameter is required for an IPv6 only subnet.

Required: Yes

Type: String

Update requires: Replacement

SubnetId

The ID of the subnet.

Required: Yes

Type: String

Update requires: Replacement

Return values

Ref

When you pass the logical ID of this resource to the intrinsic Ref function, Ref returns the association ID for the subnet’s IPv6 CIDR block.

For more information about using the Ref function, see Ref.