CfnRouteProps

class aws_cdk.aws_ec2.CfnRouteProps(*, route_table_id, carrier_gateway_id=None, destination_cidr_block=None, destination_ipv6_cidr_block=None, egress_only_internet_gateway_id=None, gateway_id=None, instance_id=None, local_gateway_id=None, nat_gateway_id=None, network_interface_id=None, transit_gateway_id=None, vpc_endpoint_id=None, vpc_peering_connection_id=None)

Bases: object

Properties for defining a CfnRoute.

Parameters:
  • route_table_id (str) – The ID of the route table for the route.

  • carrier_gateway_id (Optional[str]) – The ID of the carrier gateway. You can only use this option when the VPC contains a subnet which is associated with a Wavelength Zone.

  • destination_cidr_block (Optional[str]) – The IPv4 CIDR address block used for the destination match. Routing decisions are based on the most specific match. We modify the specified CIDR block to its canonical form; for example, if you specify 100.68.0.18/18 , we modify it to 100.68.0.0/18 .

  • destination_ipv6_cidr_block (Optional[str]) – The IPv6 CIDR block used for the destination match. Routing decisions are based on the most specific match.

  • egress_only_internet_gateway_id (Optional[str]) – [IPv6 traffic only] The ID of an egress-only internet gateway.

  • gateway_id (Optional[str]) – The ID of an internet gateway or virtual private gateway attached to your VPC.

  • instance_id (Optional[str]) – The ID of a NAT instance in your VPC. The operation fails if you specify an instance ID unless exactly one network interface is attached.

  • local_gateway_id (Optional[str]) – The ID of the local gateway.

  • nat_gateway_id (Optional[str]) – [IPv4 traffic only] The ID of a NAT gateway.

  • network_interface_id (Optional[str]) – The ID of a network interface.

  • transit_gateway_id (Optional[str]) – The ID of a transit gateway.

  • vpc_endpoint_id (Optional[str]) – The ID of a VPC endpoint. Supported for Gateway Load Balancer endpoints only.

  • vpc_peering_connection_id (Optional[str]) – The ID of a VPC peering connection.

Link:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-route.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
import aws_cdk.aws_ec2 as ec2

cfn_route_props = ec2.CfnRouteProps(
    route_table_id="routeTableId",

    # the properties below are optional
    carrier_gateway_id="carrierGatewayId",
    destination_cidr_block="destinationCidrBlock",
    destination_ipv6_cidr_block="destinationIpv6CidrBlock",
    egress_only_internet_gateway_id="egressOnlyInternetGatewayId",
    gateway_id="gatewayId",
    instance_id="instanceId",
    local_gateway_id="localGatewayId",
    nat_gateway_id="natGatewayId",
    network_interface_id="networkInterfaceId",
    transit_gateway_id="transitGatewayId",
    vpc_endpoint_id="vpcEndpointId",
    vpc_peering_connection_id="vpcPeeringConnectionId"
)

Attributes

carrier_gateway_id

The ID of the carrier gateway.

You can only use this option when the VPC contains a subnet which is associated with a Wavelength Zone.

Link:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-route.html#cfn-ec2-route-carriergatewayid

destination_cidr_block

The IPv4 CIDR address block used for the destination match.

Routing decisions are based on the most specific match. We modify the specified CIDR block to its canonical form; for example, if you specify 100.68.0.18/18 , we modify it to 100.68.0.0/18 .

Link:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-route.html#cfn-ec2-route-destinationcidrblock

destination_ipv6_cidr_block

The IPv6 CIDR block used for the destination match.

Routing decisions are based on the most specific match.

Link:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-route.html#cfn-ec2-route-destinationipv6cidrblock

egress_only_internet_gateway_id

[IPv6 traffic only] The ID of an egress-only internet gateway.

Link:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-route.html#cfn-ec2-route-egressonlyinternetgatewayid

gateway_id

The ID of an internet gateway or virtual private gateway attached to your VPC.

Link:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-route.html#cfn-ec2-route-gatewayid

instance_id

The ID of a NAT instance in your VPC.

The operation fails if you specify an instance ID unless exactly one network interface is attached.

Link:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-route.html#cfn-ec2-route-instanceid

local_gateway_id

The ID of the local gateway.

Link:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-route.html#cfn-ec2-route-localgatewayid

nat_gateway_id

[IPv4 traffic only] The ID of a NAT gateway.

Link:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-route.html#cfn-ec2-route-natgatewayid

network_interface_id

The ID of a network interface.

Link:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-route.html#cfn-ec2-route-networkinterfaceid

route_table_id

The ID of the route table for the route.

Link:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-route.html#cfn-ec2-route-routetableid

transit_gateway_id

The ID of a transit gateway.

Link:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-route.html#cfn-ec2-route-transitgatewayid

vpc_endpoint_id

The ID of a VPC endpoint.

Supported for Gateway Load Balancer endpoints only.

Link:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-route.html#cfn-ec2-route-vpcendpointid

vpc_peering_connection_id

The ID of a VPC peering connection.

Link:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-route.html#cfn-ec2-route-vpcpeeringconnectionid