我们正在尝试使用此处的文档创建 azurerm_vpn_gateway_connection https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/vpn_gateway_connection#bgp_enabled 我们正在使用
resource "azurerm_vpn_gateway_connection" "example" {
name = "example"
vpn_gateway_id = azurerm_vpn_gateway.example.id
remote_vpn_site_id = azurerm_vpn_site.example.id
vpn_link {
name = "link1"
vpn_site_link_id = azurerm_vpn_site.example.vpn_site_link[0].id
}
vpn_link {
name = "link2"
vpn_site_link_id = azurerm_vpn_site.example.vpn_site_link[1].id
}
}
运行 terraform plan 时出现错误
│ Error: Unsupported attribute
│
│ on main.tf line 95, in resource "azurerm_vpn_gateway_connection" "example":
│ 95: vpn_site_link_id = azurerm_vpn_site.example.vpn_site_link[0].id
│
│ This object has no argument, nested block, or exported attribute named "vpn_site_link".
╵