az network vhub connection
Note
This reference is part of the virtual-wan extension for the Azure CLI (version 2.0.67 or higher). The extension will automatically install the first time you run an az network vhub connection command. Learn more about extensions.
Manage virtual hub VNet connections.
Commands
| az network vhub connection create |
Create a virtual hub VNet connection. |
| az network vhub connection delete |
Delete a virtual hub VNet connection. |
| az network vhub connection list |
List virtual hub VNet connections. |
| az network vhub connection show |
Get the details of a virtual hub VNet connection. |
| az network vhub connection update |
Update settings of a virtual hub connection. |
| az network vhub connection wait |
Place the CLI in a waiting state until a condition of virtual hub VNet connection is met. |
az network vhub connection create
Create a virtual hub VNet connection.
az network vhub connection create --name
--remote-vnet
--resource-group
--vhub-name
[--address-prefixes]
[--associated]
[--internet-security {false, true}]
[--labels]
[--next-hop]
[--no-wait]
[--propagated]
[--remote-vnet-transit {false, true}]
[--route-name]
[--use-hub-vnet-gateways {false, true}]
Examples
Create a virtual hub VNet connection without routing configuration.
az network vhub connection create -n MyConnection --vhub-name MyHub -g MyRG --remote-vnet MyVNet
Create a virtual hub VNet connection with routing configuration.
az network vhub connection create -n MyConnection --vhub-name MyHub -g MyRG --remote-vnet MyVNet --associated-route-table /subscriptions/MySub/resourceGroups/MyRG/providers/Microsoft.Network/virtualHubs/MyHub/hubRouteTables/RouteTable1 --propagated-route-tables /subscriptions/MySub/resourceGroups/MyRG/providers/Microsoft.Network/virtualHubs/MyHub/hubRouteTables/RouteTable1 /subscriptions/MySub/resourceGroups/MyRG/providers/Microsoft.Network/virtualHubs/MyHub/hubRouteTables/RouteTable2 --labels label1 label2 --route-name route1 --next-hop 70.0.0.2 --address-prefixes 10.80.0.0/16 10.90.0.0/16
Required Parameters
Name of the connection.
Name of ID of the remote VNet to connect to.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Name of the virtual hub.
Optional Parameters
Space-separated list of all address prefixes.
The resource id of route table associated with this routing configuration.
Enable internet security and default is enabled.
Space-separated list of labels for propagated route tables.
The ip address of the next hop.
Do not wait for the long-running operation to finish.
Space-separated list of resource id of propagated route tables.
Enable hub to remote VNet transit.
The name of the Static Route that is unique within a Vnet Route.
Allow remote VNet to use hub's VNet gateways.
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
az network vhub connection delete
Delete a virtual hub VNet connection.
az network vhub connection delete --name
--resource-group
--vhub-name
[--no-wait]
[--yes]
Examples
Delete a virtual hub VNet connection.
az network vhub connection delete -n MyConnection --vhub-name MyHub -g MyRG
Required Parameters
Name of the connection.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Name of the virtual hub.
Optional Parameters
Do not wait for the long-running operation to finish.
Do not prompt for confirmation.
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
az network vhub connection list
List virtual hub VNet connections.
az network vhub connection list --resource-group
--vhub-name
Examples
List VNet connections in a given virtual hub.
az network vhub connection list --vhub-name MyHub -g MyRG
Required Parameters
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Name of the virtual hub.
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
az network vhub connection show
Get the details of a virtual hub VNet connection.
az network vhub connection show --name
--resource-group
--vhub-name
Examples
Get the details of a virtual hub VNet connection.
az network vhub connection show -n MyConnection --vhub-name MyHub -g MyRG
Required Parameters
Name of the connection.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Name of the virtual hub.
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
az network vhub connection update
Update settings of a virtual hub connection.
az network vhub connection update --name
--resource-group
--vhub-name
[--add]
[--associated]
[--force-string]
[--labels]
[--no-wait]
[--propagated]
[--remove]
[--set]
Examples
Add labels of a virtual hub connection.
az network vhub connection update -n MyConnection --vhub-name MyHub -g MyRG --labels Newlabel1 Newlabel2
Add labels for propagatedRouteTables of a virtual hub connection.
az network vhub connection update -n MyConnection --vhub-name MyHub -g MyRG --add routingConfiguration.propagatedRouteTables.labels Newlabel1 Newlabel2
Reset labels of a virtual hub connection.
az network vhub connection update -n MyConnection --vhub-name MyHub -g MyRG --set routingConfiguration.propagatedRouteTables.labels[0]=Newlabel
Required Parameters
Name of the connection.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Name of the virtual hub.
Optional Parameters
Add an object to a list of objects by specifying a path and key value pairs. Example: --add property.listProperty <key=value, string or JSON string>.
The resource id of route table associated with this routing configuration.
When using 'set' or 'add', preserve string literals instead of attempting to convert to JSON.
Space-separated list of labels for propagated route tables.
Do not wait for the long-running operation to finish.
Space-separated list of resource id of propagated route tables.
Remove a property or an element from a list. Example: --remove property.list OR --remove propertyToRemove.
Update an object by specifying a property path and value to set. Example: --set property1.property2=.
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
az network vhub connection wait
Place the CLI in a waiting state until a condition of virtual hub VNet connection is met.
az network vhub connection wait --name
--resource-group
--vhub-name
[--created]
[--custom]
[--deleted]
[--exists]
[--interval]
[--timeout]
[--updated]
Required Parameters
Name of the connection.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Name of the virtual hub.
Optional Parameters
Wait until created with 'provisioningState' at 'Succeeded'.
Wait until the condition satisfies a custom JMESPath query. E.g. provisioningState!='InProgress', instanceView.statuses[?code=='PowerState/running'].
Wait until deleted.
Wait until the resource exists.
Polling interval in seconds.
Maximum wait in seconds.
Wait until updated with provisioningState at 'Succeeded'.
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
الملاحظات
إرسال الملاحظات وعرضها المتعلقة بـ