Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

awscc.ec2_route_table

CloudFormation Type: AWS::EC2::RouteTable

Specifies a route table for the specified VPC. After you create a route table, you can add routes and associate the table with a subnet. For more information, see Route tables in the Amazon VPC User Guide.

Attributes

NameTypeRequiredDescription
route_table_idString(read-only)
tagsMapNoAny tags assigned to the route table.
vpc_idStringYesThe ID of the VPC.

Example

let vpc = awscc.ec2_vpc {
  name                 = "example-vpc"
  cidr_block           = "10.0.0.0/16"
  enable_dns_support   = true
  enable_dns_hostnames = true
}

awscc.ec2_route_table {
  name   = "example-public-rt"
  vpc_id = vpc.vpc_id

  tags = {
    Environment = "example"
  }
}