RouteTableProps
- class aws_cdk.aws_ec2_alpha.RouteTableProps(*, vpc, route_table_name=None)
Bases:
object
(experimental) Properties to define a route table.
- Parameters:
vpc (
IVpcV2
) – (experimental) The ID of the VPC.route_table_name (
Optional
[str
]) – (experimental) The resource name of the route table. Default: - provisioned without a route table name
- Stability:
experimental
- ExampleMetadata:
infused
Example:
stack = Stack() my_vpc = VpcV2(self, "Vpc") vpn_gateway = my_vpc.enable_vpn_gateway_v2( vpn_route_propagation=[ec2.SubnetSelection(subnet_type=SubnetType.PUBLIC)], type=VpnConnectionType.IPSEC_1 ) route_table = RouteTable(stack, "routeTable", vpc=my_vpc ) Route(stack, "route", destination="172.31.0.0/24", target={"gateway": vpn_gateway}, route_table=route_table )
Attributes
- route_table_name
(experimental) The resource name of the route table.
- Default:
provisioned without a route table name
- Stability:
experimental
- vpc
(experimental) The ID of the VPC.
- Stability:
experimental