az stack-hci-vm network nat inbound-rule
Note
This reference is part of the stack-hci-vm extension for the Azure CLI (version 2.15.0 or higher). The extension will automatically install the first time you run an az stack-hci-vm network nat inbound-rule command. Learn more about extensions.
Manage inbound NAT rules with stack-hci-vm.
Commands
| Name | Description | Type | Status |
|---|---|---|---|
| az stack-hci-vm network nat inbound-rule create |
Create an inbound NAT rule. |
Extension | GA |
| az stack-hci-vm network nat inbound-rule delete |
Delete an inbound NAT rule. |
Extension | GA |
| az stack-hci-vm network nat inbound-rule list |
List all inbound NAT rules in a NAT gateway. |
Extension | GA |
| az stack-hci-vm network nat inbound-rule show |
Get the details of an inbound NAT rule. |
Extension | GA |
az stack-hci-vm network nat inbound-rule create
Create an inbound NAT rule.
az stack-hci-vm network nat inbound-rule create --backend-ip-config
--backend-port
--frontend-port
--name
--nat-gateway-name
--protocol
--public-ip-address
--resource-group
[--acquire-policy-token]
[--change-reference]
[--custom-location]
[--location]
[--polling-interval]
[--tags]
Examples
CreateInboundRule
az stack-hci-vm network nat inbound-rule create --resource-group "test-rg" --nat-gateway-name "test-nat" --name "sshRule" --location "eastus" --custom-location "/subscriptions/xxxx/resourceGroups/test-rg/providers/Microsoft.ExtendedLocation/customLocations/test-location" --protocol "Tcp" --frontend-port 2222 --backend-port 22 --backend-ip-config "/subscriptions/xxxx/resourceGroups/test-rg/providers/Microsoft.Network/networkInterfaces/vm1nic/ipConfigurations/ipconfig1" --public-ip-address "/subscriptions/xxxx/resourceGroups/test-rg/providers/Microsoft.Network/publicIPAddresses/test-pip1"
Required Parameters
Resource ID of the backend IP configuration.
Backend port for the inbound rule.
Frontend port for the inbound rule.
Name of the inbound NAT rule.
Name of the NAT gateway.
Protocol for the NAT rule. Allowed values: Tcp, Udp.
Resource ID of the public IP address for this NAT rule.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
Acquiring an Azure Policy token automatically for this resource operation.
| Property | Value |
|---|---|
| Parameter group: | Global Policy Arguments |
The related change reference ID for this resource operation.
| Property | Value |
|---|---|
| Parameter group: | Global Policy Arguments |
The ID of the custom location. If omitted, inherited from the parent NAT gateway.
If location is not specified, the location of the resource group is used.
ARM polling interval for long running operations.
Space-separated tags: key[=value] [key[=value] ...]. Use "" to clear existing tags.
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
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.
| Property | Value |
|---|---|
| Default value: | False |
az stack-hci-vm network nat inbound-rule delete
Delete an inbound NAT rule.
az stack-hci-vm network nat inbound-rule delete --name
--nat-gateway-name
--resource-group
[--acquire-policy-token]
[--change-reference]
[--polling-interval]
[--yes]
Examples
DeleteInboundRule
az stack-hci-vm network nat inbound-rule delete --resource-group "test-rg" --nat-gateway-name "test-nat" --name "sshRule" --yes
Required Parameters
Name of the inbound NAT rule.
Name of the NAT gateway.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
Acquiring an Azure Policy token automatically for this resource operation.
| Property | Value |
|---|---|
| Parameter group: | Global Policy Arguments |
The related change reference ID for this resource operation.
| Property | Value |
|---|---|
| Parameter group: | Global Policy Arguments |
ARM polling interval for long running operations.
Do not prompt for confirmation.
| Property | Value |
|---|---|
| Default value: | False |
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
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.
| Property | Value |
|---|---|
| Default value: | False |
az stack-hci-vm network nat inbound-rule list
List all inbound NAT rules in a NAT gateway.
az stack-hci-vm network nat inbound-rule list --nat-gateway-name
--resource-group
Examples
ListInboundRules
az stack-hci-vm network nat inbound-rule list --resource-group "test-rg" --nat-gateway-name "test-nat"
Required Parameters
Name of the NAT gateway.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
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.
| Property | Value |
|---|---|
| Default value: | False |
az stack-hci-vm network nat inbound-rule show
Get the details of an inbound NAT rule.
az stack-hci-vm network nat inbound-rule show --name
--nat-gateway-name
--resource-group
Examples
ShowInboundRule
az stack-hci-vm network nat inbound-rule show --resource-group "test-rg" --nat-gateway-name "test-nat" --name "sshRule"
Required Parameters
Name of the inbound NAT rule.
Name of the NAT gateway.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
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.
| Property | Value |
|---|---|
| Default value: | False |