az acr network-rule

Manage network rules for Azure Container Registries.

Commands

Name Description Type Status
az acr network-rule add

Add a network rule.

Core GA
az acr network-rule list

List network rules.

Core GA
az acr network-rule remove

Remove a network rule.

Core GA

az acr network-rule add

Add a network rule.

az acr network-rule add --name
                        [--ip-address]
                        [--resource-group]
                        [--subnet]
                        [--vnet-name]

Examples

Add a rule to allow access for a specific IP address-range.

az acr network-rule add -n myregistry --ip-address 23.45.1.0/24

Required Parameters

--name -n

The name of the container registry. It should be specified in lower case. You can configure the default registry name using az configure --defaults acr=<registry name>.

Optional Parameters

--ip-address

IPv4 address or CIDR range.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

--subnet
Deprecated

Argument 'subnet' has been deprecated and will be removed in a future release.

Name or ID of subnet. If name is supplied, --vnet-name must be supplied.

--vnet-name
Deprecated

Argument 'vnet_name' has been deprecated and will be removed in a future release.

Name of a virtual network.

Global Parameters
--debug

Increase logging verbosity to show all debug logs.

--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

--output -o

Output format.

Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
Default value: json
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

az acr network-rule list

List network rules.

az acr network-rule list --name
                         [--resource-group]

Examples

List network rules for a registry.

az acr network-rule list -n myregistry

Required Parameters

--name -n

The name of the container registry. It should be specified in lower case. You can configure the default registry name using az configure --defaults acr=<registry name>.

Optional Parameters

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

Global Parameters
--debug

Increase logging verbosity to show all debug logs.

--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

--output -o

Output format.

Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
Default value: json
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

az acr network-rule remove

Remove a network rule.

az acr network-rule remove --name
                           [--ip-address]
                           [--resource-group]
                           [--subnet]
                           [--vnet-name]

Examples

Remove a rule that allows access for a specific IP address-range.

az acr network-rule remove -n myregistry --ip-address 23.45.1.0/24

Required Parameters

--name -n

The name of the container registry. It should be specified in lower case. You can configure the default registry name using az configure --defaults acr=<registry name>.

Optional Parameters

--ip-address

IPv4 address or CIDR range.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

--subnet
Deprecated

Argument 'subnet' has been deprecated and will be removed in a future release.

Name or ID of subnet. If name is supplied, --vnet-name must be supplied.

--vnet-name
Deprecated

Argument 'vnet_name' has been deprecated and will be removed in a future release.

Name of a virtual network.

Global Parameters
--debug

Increase logging verbosity to show all debug logs.

--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

--output -o

Output format.

Accepted values: json, jsonc, none, table, tsv, yaml, yamlc
Default value: json
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--verbose

Increase logging verbosity. Use --debug for full debug logs.