Using Terraform, I have created the Transit Gateway, VPN definitions and associated them with the Transit Gateway. However, unable to to define static routes.
when trying to add the static routes, the error says it must be added via the Transit Gateway API. However, I cannot find that syntax.
resource "aws_vpn_connection_route" "vpn-p-usw2-xxxxxx-route-001" {
destination_cidr_block = "10.10.0.0/16"
vpn_connection_id = "${aws_vpn_connection.vpn-p-usw2-xxxxxx.id}"
}
Error: Error creating VPN connection route:
InvalidVpnConnection.InvalidType: Static routes for vpn-0f6d1ac578b957bf1
must be added through the Transit Gateway API.
status code: 400, request id:
f4e1c61c-be16-4dc7-a608- d7a5d6ad57c7