| « PreviousNext » | |
![]() ![]() ![]() | Did this page help you? Yes | No | Tell us about it... |
Creates a new route table within a VPC. After you create a new route table, you can add routes and associate the table with a subnet.
{
"Type" : "AWS::EC2::RouteTable",
"Properties" : {
"VpcId" : String,
"Tags" : [ EC2 Tag, ... ]
}
} The ID of the VPC where the route table will be created.
Example: vpc-11ad4878
Required: Yes
Type: String
Update requires: replacement
The tags you want to attach to this resource.
Required: No
Type: List of EC2 Tags
Update requires: no interruption
When the logical ID of this resource is provided to the Ref intrinsic
function, it returns the resource name.
For more information about using the Ref function, see Ref.
Example
The following example snippet uses the VPC ID from a VPC named myVPC that was declared elsewhere in the same template.
{
"AWSTemplateFormatVersion" : "2010-09-09",
"Resources" : {
"myRouteTable" : {
"Type" : "AWS::EC2::RouteTable",
"Properties" : {
"VpcId" : { "Ref" : "myVPC" },
"Tags" : [ { "Key" : "foo", "Value" : "bar" } ]
}
}
}
} CreateRouteTable in the Amazon Elastic Compute Cloud API Reference
Route Tables in the Amazon Virtual Private Cloud User Guide
Using Tags in the Amazon Elastic Compute Cloud User Guide