Hi Guys,
I am trying to create one route in my routing table to connect with an internet gateway. But it is showing me the below error.
resource "aws_route_table" "table" {
vpc_id = "${aws_vpc.main.id}"
route {
cidr_block = "10.0.1.0/0"
gateway_id = "${aws_internet_gateway.gw.id}"
}
tags = {
Name = "MyRoute"
}
}
Error: Error creating route: InvalidParameterValue: Route target is not supported. This route only supports interface and instance targets.
How can I solve this error?