Skip to content

Commit 1cf0552

Browse files
authored
Merge pull request #115698 from dlepow/acrlink
[ACR] public-network-enabled
2 parents 174ee88 + a06c642 commit 1cf0552

File tree

3 files changed

+50
-14
lines changed

3 files changed

+50
-14
lines changed

articles/container-registry/TOC.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@
9191
items:
9292
- name: Restrict access using private endpoint
9393
href: container-registry-private-link.md
94-
- name: Configure service firewall rules
94+
- name: Configure public registry access
9595
href: container-registry-access-selected-networks.md
9696
- name: Restrict access using service endpoint (preview)
9797
href: container-registry-vnet.md

articles/container-registry/container-registry-access-selected-networks.md

Lines changed: 32 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
---
2-
title: Configure service firewall rules
2+
title: Configure public registry access
33
description: Configure IP rules to enable access to an Azure container registry from selected public IP addresses or address ranges.
44
ms.topic: article
5-
ms.date: 05/04/2020
5+
ms.date: 05/19/2020
66
---
77

88
# Configure public IP network rules
@@ -54,24 +54,46 @@ az acr network-rule add \
5454
5555
## Disable public network access
5656

57-
To limit traffic to virtual networks using [Private Link](container-registry-private-link.md), disable the public endpoint on the registry. Disabling the public endpoint overrides all firewall configurations.
57+
Optionally, disable the public endpoint on the registry. Disabling the public endpoint overrides all firewall configurations. For example, you might want to disable public access to a registry secured in a virtual network using [Private Link](container-registry-private-link.md).
5858

59-
### Disable public access - Portal
59+
### Disable public access - CLI
60+
61+
To disable public access using the Azure CLI, run [az acr update][az-acr-update] and set `--public-network-enabled` to `false`.
62+
63+
> [!NOTE]
64+
> The `public-network-enabled` argument requires Azure CLI 2.6.0 or later.
65+
66+
```azurecli
67+
az acr update --name myContainerRegistry --public-network-enabled false
68+
```
69+
70+
### Disable public access - portal
6071

6172
1. In the portal, navigate to your container registry and select **Settings > Networking**.
62-
1. On the **Public access** tab, in **Allow public access**, select **Disabled**. Then select **Save**.
73+
1. On the **Public access** tab, in **Allow public network access**, select **Disabled**. Then select **Save**.
6374

6475
![Disable public access][acr-access-disabled]
6576

66-
## Restore default registry access
6777

68-
To restore the registry to allow access by default, update the default action.
78+
## Restore public network access
79+
80+
To re-enable the public endpoint, update the networking settings to allow public access. Enabling the public endpoint overrides all firewall configurations.
81+
82+
### Restore public access - CLI
83+
84+
Run [az acr update][az-acr-update] and set `--public-network-enabled` to `true`.
85+
86+
> [!NOTE]
87+
> The `public-network-enabled` argument requires Azure CLI 2.6.0 or later.
88+
89+
```azurecli
90+
az acr update --name myContainerRegistry --public-network-enabled true
91+
```
6992

70-
### Restore default registry access - portal
93+
### Restore public access - portal
7194

7295
1. In the portal, navigate to your container registry and select **Settings > Networking**.
73-
1. Under **Firewall**, select each address range, and then select the Delete icon.
74-
1. On the **Public access** tab, in **Allow public access**, select **All networks**. Then select **Save**.
96+
1. On the **Public access** tab, in **Allow public network access**, select **All networks**. Then select **Save**.
7597

7698
![Public access from all networks][acr-access-all-networks]
7799

articles/container-registry/container-registry-private-link.md

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: Set up private link
33
description: Set up a private endpoint on a container registry and enable access over a private link in a local virtual network
44
ms.topic: article
5-
ms.date: 05/07/2020
5+
ms.date: 05/19/2020
66
---
77

88
# Configure Azure Private Link for an Azure container registry
@@ -19,7 +19,7 @@ This feature is available in the **Premium** container registry service tier. Fo
1919

2020
## Prerequisites
2121

22-
* To use the Azure CLI steps in this article, Azure CLI version 2.2.0 or later is recommended. If you need to install or upgrade, see [Install Azure CLI][azure-cli]. Or run in [Azure Cloud Shell](../cloud-shell/quickstart.md).
22+
* To use the Azure CLI steps in this article, Azure CLI version 2.6.0 or later is recommended. If you need to install or upgrade, see [Install Azure CLI][azure-cli]. Or run in [Azure Cloud Shell](../cloud-shell/quickstart.md).
2323
* If you don't already have a container registry, create one (Premium tier required) and [import](container-registry-import-images.md) a sample image such as `hello-world` from Docker Hub. For example, use the [Azure portal][quickstart-portal] or the [Azure CLI][quickstart-cli] to create a registry.
2424
* To configure registry access using a private link in a different Azure subscription, you need to register the resource provider for Azure Container Registry in that subscription. For example:
2525

@@ -277,7 +277,21 @@ Your private link is now configured and ready for use.
277277

278278
## Disable public access
279279

280-
For many scenarios, disable registry access from public networks. This configuration prevents clients outside the virtual network from reaching the registry endpoints. To disable public access using the portal:
280+
For many scenarios, disable registry access from public networks. This configuration prevents clients outside the virtual network from reaching the registry endpoints.
281+
282+
### Disable public access - CLI
283+
284+
To disable public access using the Azure CLI, run [az acr update][az-acr-update] and set `--public-network-enabled` to `false`.
285+
286+
> [!NOTE]
287+
> The `public-network-enabled` argument requires Azure CLI 2.6.0 or later.
288+
289+
```azurecli
290+
az acr update --name $REGISTRY_NAME --public-network-enabled false
291+
```
292+
293+
294+
### Disable public access - portal
281295

282296
1. In the portal, navigate to your container registry and select **Settings > Networking**.
283297
1. On the **Public access** tab, in **Allow public access**, select **Disabled**. Then select **Save**.

0 commit comments

Comments
 (0)