Skip to content

Commit eaa1155

Browse files
authored
Merge pull request #198710 from alexandair/patch-28-pr
Fix a description for the PowerShell and Azure CLI tabs
2 parents a83c2d9 + 009f725 commit eaa1155

File tree

1 file changed

+21
-12
lines changed

1 file changed

+21
-12
lines changed

articles/container-registry/buffer-gate-public-content.md

Lines changed: 21 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -63,15 +63,14 @@ For details, see [Docker Hub authenticated pulls on App Service](https://azure.g
6363

6464
To begin managing copies of public images, you can create an Azure container registry if you don't already have one. Create a registry using the [Azure CLI](container-registry-get-started-azure-cli.md), [Azure portal](container-registry-get-started-portal.md), [Azure PowerShell](container-registry-get-started-powershell.md), or other tools.
6565

66+
# [Azure CLI](#tab/azure-cli)
67+
6668
As a recommended one-time step, [import](container-registry-import-images.md) base images and other public content to your Azure container registry. The [az acr import](/cli/azure/acr#az-acr-import) command in the Azure CLI supports image import from public registries such as Docker Hub and Microsoft Container Registry and from other private container registries.
6769

6870
`az acr import` doesn't require a local Docker installation. You can run it with a local installation of the Azure CLI or directly in Azure Cloud Shell. It supports images of any OS type, multi-architecture images, or OCI artifacts such as Helm charts.
6971

7072
Depending on your organization's needs, you can import to a dedicated registry or a repository in a shared registry.
7173

72-
# [Azure CLI](#tab/azure-cli)
73-
Example:
74-
7574
```azurecli-interactive
7675
az acr import \
7776
--name myregistry \
@@ -81,18 +80,28 @@ az acr import \
8180
--password <Docker Hub token>
8281
```
8382

84-
# [PowerShell](#tab/azure-powershell)
85-
Example:
83+
# [Azure PowerShell](#tab/azure-powershell)
84+
85+
As a recommended one-time step, [import](container-registry-import-images.md) base images and other public content to your Azure container registry. The [Import-AzContainerRegistryImage](/powershell/module/az.containerregistry/import-azcontainerregistryimage) command in the Azure PowerShell supports image import from public registries such as Docker Hub and Microsoft Container Registry and from other private container registries.
86+
87+
`Import-AzContainerRegistryImage` doesn't require a local Docker installation. You can run it with a local installation of the Azure PowerShell or directly in Azure Cloud Shell. It supports images of any OS type, multi-architecture images, or OCI artifacts such as Helm charts.
88+
89+
Depending on your organization's needs, you can import to a dedicated registry or a repository in a shared registry.
8690

8791
```azurepowershell-interactive
88-
Import-AzContainerRegistryImage
89-
-SourceImage library/busybox:latest
90-
-ResourceGroupName $resourceGroupName
91-
-RegistryName $RegistryName
92-
-SourceRegistryUri docker.io
93-
-TargetTag busybox:latest
92+
$Params = @{
93+
SourceImage = 'library/busybox:latest'
94+
ResourceGroupName = $resourceGroupName
95+
RegistryName = $RegistryName
96+
SourceRegistryUri = 'docker.io'
97+
TargetTag = 'busybox:latest'
98+
}
99+
Import-AzContainerRegistryImage @Params
94100
```
95-
Credentials are required if the source registry is not available publicly or the admin user is disabled.
101+
102+
Credentials are required if the source registry is not available publicly or the admin user is disabled.
103+
104+
---
96105

97106
## Update image references
98107

0 commit comments

Comments
 (0)