简体   繁体   中英

How to update Route Table and Security Configuration of Azure Virtual Hub using Terraform

I have created an Azure Virtual WAN along with Secure Azure Virtual Hub using Terraform scripts. For that I have followed this documentation .

I want to add the route table configuration to the Azure Virtual Hub using Terraform. Azure Virtual Hub 的路由表配置

And then secure the Private Traffic of all virtual connections inside an Azure Virtual Hub Security Configuration using Terraform.

虚拟 HUB 安全配置

There currently doesn't seem to be a way to update the default or none routing tables in a .net hub as there isn't an API for vhub route table routes as you can see in the discussion from this feature request .

Here's what I did:

  1. I created a custom vhub route table with the desired routes (I'm using all_traffic) but use whatever.
  2. I then added a routing block to the vpn connections and .net hub connection.

Now when I list the routing tables ( az.network vhub route-table list --resource-group <your_group> --vhub-name <vhub name> ) I can see that my new routing table is associated to the hubVirtualNetworkConnections

The only downside I've noticed so far is that the UI shows the connections as unsecured, though it seems to be working properly. As mentioned in the documentation, it seems the UI is picky and only reflects correctly using the default route table and the correct route names.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM