az acr
Note
此命令群組具有 Azure CLI 和至少一個擴充功能中定義的命令。 安裝每個擴充功能以受益於其擴充功能。 Learn more about extensions.
使用 Azure Container Registries 管理私人登錄。
命令
名稱 | Description | 類型 | 狀態 |
---|---|---|---|
az acr agentpool |
使用 Azure 容器登錄管理私人工作代理程式集區。 |
Core | Preview |
az acr agentpool create |
建立 Azure Container Registry 的代理程式集區。 |
Core | Preview |
az acr agentpool delete |
刪除代理程式集區。 |
Core | Preview |
az acr agentpool list |
列出 Azure Container Registry 的代理程式集區。 |
Core | Preview |
az acr agentpool show |
取得 Azure Container Registry 指定之代理程式集區的屬性。 |
Core | Preview |
az acr agentpool update |
更新 Azure Container Registry 的代理程式集區。 |
Core | Preview |
az acr artifact-streaming |
管理 ACR 中任何存放庫或支援映像的成品串流。 |
Core | Preview |
az acr artifact-streaming create |
為 ACR 中的特定映像建立查閱者串流成品。 |
Core | Preview |
az acr artifact-streaming operation |
管理 ACR 的串流成品建立作業。 |
Core | Preview |
az acr artifact-streaming operation cancel |
取消 ACR 的指定串流成品作業。 |
Core | Preview |
az acr artifact-streaming operation show |
檢查 ACR 中成品串流的作業狀態。 |
Core | Preview |
az acr artifact-streaming show |
顯示是否已在 Azure Container Registry 的存放庫中啟用成品串流。 |
Core | Preview |
az acr artifact-streaming update |
為指定登錄下新推送的映像啟用或停用串流成品的自動建立。 |
Core | Preview |
az acr build |
將快速建置排入佇列,為 Azure Container Registry 提供串流記錄。 |
Core | GA |
az acr cache |
在 Azure Container Registries 中管理快取規則。 |
Core | GA |
az acr cache create |
建立快取規則。 |
Core | GA |
az acr cache delete |
刪除快取規則。 |
Core | GA |
az acr cache list |
列出 Azure Container Registry 中的快取規則。 |
Core | GA |
az acr cache show |
顯示快取規則。 |
Core | GA |
az acr cache update |
更新快取規則上的認證集。 |
Core | GA |
az acr check-health |
取得環境的健康情況資訊,並選擇性地取得目標登錄。 |
Core | GA |
az acr check-name |
檢查 Azure Container Registry 名稱是否有效且可供使用。 |
Core | GA |
az acr config |
設定 Azure Container Registries 的原則。 |
Core | GA |
az acr config authentication-as-arm |
管理 Azure 容器登錄的「Azure AD 驗證為 ARM」原則。 |
Core | Preview |
az acr config authentication-as-arm show |
針對 Azure Container Registry 顯示已設定的「Azure AD 驗證為 ARM」原則。 |
Core | Preview |
az acr config authentication-as-arm update |
更新 Azure Container Registry 的「Azure AD 驗證為 ARM」原則。 |
Core | Preview |
az acr config content-trust |
管理 Azure Container Registries 的內容信任原則。 |
Core | GA |
az acr config content-trust show |
顯示 Azure Container Registry 設定的內容信任原則。 |
Core | GA |
az acr config content-trust update |
更新 Azure Container Registry 的內容信任原則。 |
Core | GA |
az acr config retention |
管理 Azure Container Registries 的保留原則。 |
Core | Preview |
az acr config retention show |
顯示 Azure Container Registry 的已設定保留原則。 |
Core | Preview |
az acr config retention update |
更新 Azure Container Registry 的保留原則。 |
Core | Preview |
az acr config soft-delete |
管理 Azure Container Registries 的虛刪除原則。 |
Core | Preview |
az acr config soft-delete show |
顯示 Azure Container Registry 的已設定虛刪除原則。 |
Core | Preview |
az acr config soft-delete update |
更新 Azure Container Registry 的虛刪除原則。 |
Core | Preview |
az acr connected-registry |
使用 Azure Container Registries 管理已連線的登錄資源。 |
Core | GA |
az acr connected-registry create |
建立 Azure Container Registry 的連線登錄。 |
Core | GA |
az acr connected-registry deactivate |
從 Azure Container Registry 停用已連線的登錄。 |
Core | GA |
az acr connected-registry delete |
從 Azure Container Registry 刪除已連線的登錄。 |
Core | GA |
az acr connected-registry get-settings |
擷取啟動連線登錄所需的資訊,並建立或輪替同步令牌認證。 |
Core | GA |
az acr connected-registry list |
列出目前父登錄下的所有已連線登錄。 |
Core | GA |
az acr connected-registry list-client-tokens |
列出與特定連線登錄相關聯的所有用戶端令牌。 |
Core | GA |
az acr connected-registry permissions |
管理多個已連線登錄的存放庫許可權。 如需詳細資訊,請參閱 https://aka.ms/acr/connected-registry 。 |
Core | GA |
az acr connected-registry permissions show |
顯示連線的登錄同步範圍對應資訊。 |
Core | GA |
az acr connected-registry permissions update |
在所有必要的連線登錄同步範圍對應中新增和移除存放庫許可權。 |
Core | GA |
az acr connected-registry show |
顯示線上的登錄詳細數據。 |
Core | GA |
az acr connected-registry update |
更新 Azure Container Registry 的已連線登錄。 |
Core | GA |
az acr create |
建立 Azure Container Registry。 |
Core | GA |
az acr credential |
管理 Azure Container Registries 的登入認證。 |
Core | GA |
az acr credential-set |
管理 Azure Container Registries 中的認證集。 |
Core | GA |
az acr credential-set create |
建立認證集。 |
Core | GA |
az acr credential-set delete |
刪除認證集。 |
Core | GA |
az acr credential-set list |
列出 Azure Container Registry 中的認證集。 |
Core | GA |
az acr credential-set show |
顯示認證集。 |
Core | GA |
az acr credential-set update |
更新認證集上的使用者名稱或密碼 Azure 金鑰保存庫 秘密標識碼。 |
Core | GA |
az acr credential renew |
重新產生 Azure Container Registry 的登入認證。 |
Core | GA |
az acr credential show |
取得 Azure Container Registry 的登入認證。 |
Core | GA |
az acr delete |
刪除 Azure Container Registry。 |
Core | GA |
az acr encryption |
管理容器登錄加密。 |
Core | GA |
az acr encryption rotate-key |
輪替容器登錄的加密金鑰(更新)。 |
Core | GA |
az acr encryption show |
顯示容器登錄的加密詳細數據。 |
Core | GA |
az acr export-pipeline |
管理 ACR 匯出管線。 |
Extension | Preview |
az acr export-pipeline create |
建立導出管線。 |
Extension | Preview |
az acr export-pipeline delete |
刪除匯出管線。 |
Extension | Preview |
az acr export-pipeline list |
列出 Container Registry 上的導出管線。 |
Extension | Preview |
az acr export-pipeline show |
詳細顯示匯出管線。 |
Extension | Preview |
az acr helm |
管理 Azure 容器登錄的 Helm 圖表。 |
Core | Deprecated |
az acr helm delete |
刪除 Azure Container Registry 中的 Helm 圖表版本。 |
Core | Deprecated |
az acr helm install-cli |
下載並安裝 Helm 命令行工具。 |
Core | 預覽和已淘汰 |
az acr helm list |
列出 Azure Container Registry 中的所有 Helm 圖表。 |
Core | Deprecated |
az acr helm push |
將 Helm 圖表套件推送至 Azure Container Registry。 |
Core | Deprecated |
az acr helm repo |
管理 Azure Container Registry 的 Helm 圖表存放庫。 |
Core | Deprecated |
az acr helm repo add |
透過 Helm CLI 從 Azure Container Registry 新增 Helm 圖表存放庫。 |
Core | Deprecated |
az acr helm show |
描述 Azure Container Registry 中的 Helm 圖表。 |
Core | Deprecated |
az acr identity |
管理容器登錄的服務(受控)身分識別。 |
Core | GA |
az acr identity assign |
將受控識別指派給容器登錄。 |
Core | GA |
az acr identity remove |
從容器登錄中移除受控識別。 |
Core | GA |
az acr identity show |
顯示容器登錄的身分識別詳細數據。 |
Core | GA |
az acr import |
從另一個 Container Registry 將映射匯入至 Azure Container Registry。 匯入會移除 docker pull、docker tag、docker push 的需求。 對於較大的影像,請考慮使用 |
Core | GA |
az acr import-pipeline |
管理 ACR 匯入管線。 |
Extension | Preview |
az acr import-pipeline create |
建立匯入管線。 |
Extension | Preview |
az acr import-pipeline delete |
刪除匯入管線。 |
Extension | Preview |
az acr import-pipeline list |
列出 Container Registry 上的匯入管線。 |
Extension | Preview |
az acr import-pipeline show |
詳細顯示匯入管線。 |
Extension | Preview |
az acr list |
列出目前訂用帳戶下的所有容器登錄。 |
Core | GA |
az acr login |
透過 Docker CLI 登入 Azure Container Registry。 |
Core | GA |
az acr manifest |
在 Azure Container Registries 中管理成品指令清單。 |
Core | Preview |
az acr manifest delete |
刪除 Azure Container Registry 中的指令清單。 |
Core | Preview |
az acr manifest list |
列出 Azure Container Registry 中存放庫中的指令清單。 |
Core | Preview |
az acr manifest list-deleted |
列出 Azure Container Registry 中存放庫中的虛刪除指令清單。 |
Core | Preview |
az acr manifest list-deleted-tags |
列出 Azure Container Registry 中存放庫中的虛刪除標籤。 |
Core | Preview |
az acr manifest list-metadata |
列出 Azure Container Registry 中存放庫中指令清單的元數據。 |
Core | Preview |
az acr manifest list-referrers |
列出 Azure Container Registry 中指令清單的參考者。 |
Core | Preview |
az acr manifest restore |
還原 Azure Container Registry 中的虛刪除成品和標籤。 |
Core | Preview |
az acr manifest show |
在 Azure Container Registry 中取得指令清單。 |
Core | Preview |
az acr manifest show-metadata |
取得 Azure Container Registry 中成品的元數據。 |
Core | Preview |
az acr manifest update-metadata |
更新 Azure Container Registry 中成品的指令清單元數據。 |
Core | Preview |
az acr network-rule |
管理 Azure Container Registries 的網路規則。 |
Core | GA |
az acr network-rule add |
新增網路規則。 |
Core | GA |
az acr network-rule list |
列出網路規則。 |
Core | GA |
az acr network-rule remove |
移除網路規則。 |
Core | GA |
az acr pack |
管理使用 Cloud Native Buildpacks 的 Azure Container Registry 工作。 |
Core | Preview |
az acr pack build |
將建置應用程式的快速建置工作排入佇列,並將其推送至 Azure Container Registry。 |
Core | Preview |
az acr pipeline-run |
管理 ACR 匯入和匯出管線執行。 |
Extension | Preview |
az acr pipeline-run clean |
刪除登錄上所有失敗的管線執行。 |
Extension | Preview |
az acr pipeline-run create |
建立管線執行。 |
Extension | Preview |
az acr pipeline-run delete |
刪除管線執行。 |
Extension | Preview |
az acr pipeline-run list |
列出容器登錄上所有管線的管線執行。 |
Extension | Preview |
az acr pipeline-run show |
詳細顯示管線執行。 |
Extension | Preview |
az acr private-endpoint-connection |
管理容器登錄私人端點連線。 |
Core | GA |
az acr private-endpoint-connection approve |
核准容器登錄的私人端點連線要求。 |
Core | GA |
az acr private-endpoint-connection delete |
刪除容器登錄的私人端點連線要求。 |
Core | GA |
az acr private-endpoint-connection list |
列出容器登錄的所有私人端點連線。 |
Core | GA |
az acr private-endpoint-connection reject |
拒絕容器登錄的私人端點連線要求。 |
Core | GA |
az acr private-endpoint-connection show |
顯示容器登錄私人端點連線的詳細數據。 |
Core | GA |
az acr private-link-resource |
管理登錄私人鏈接資源。 |
Core | GA |
az acr private-link-resource list |
列出登錄支援的私人鏈接資源。 |
Core | GA |
az acr query |
使用 Kusto 查詢語言查詢 ACR 中的內容。 |
Extension | GA |
az acr replication |
管理 Azure 容器登錄的異地複寫區域。 |
Core | GA |
az acr replication create |
建立 Azure Container Registry 的複寫區域。 |
Core | GA |
az acr replication delete |
從 Azure Container Registry 刪除復寫的區域。 |
Core | GA |
az acr replication list |
列出異地復寫 Azure Container Registry 的所有區域。 |
Core | GA |
az acr replication show |
取得複寫區域的詳細數據。 |
Core | GA |
az acr replication update |
更新複寫。 |
Core | GA |
az acr repository |
管理 Azure Container Registries 的存放庫(映像名稱)。 |
Core | GA |
az acr repository delete |
刪除 Azure Container Registry 中的存放庫或映像。 |
Core | GA |
az acr repository list |
列出 Azure Container Registry 中的存放庫。 |
Core | GA |
az acr repository list-deleted |
列出 Azure Container Registry 中的虛刪除存放庫。 |
Core | Preview |
az acr repository show |
取得 Azure Container Registry 中存放庫或映像的屬性。 |
Core | GA |
az acr repository show-tags |
在 Azure Container Registry 中顯示存放庫的標籤。 |
Core | GA |
az acr repository untag |
在 Azure Container Registry 中取消標記映像。 |
Core | GA |
az acr repository update |
更新 Azure Container Registry 中存放庫或映像的屬性。 |
Core | GA |
az acr run |
將快速執行排入佇列,以提供 Azure Container Registry 的串流記錄。 |
Core | GA |
az acr scope-map |
管理 Azure Container Registry 的範圍存取對應。 |
Core | GA |
az acr scope-map create |
建立 Azure Container Registry 的範圍對應。 |
Core | GA |
az acr scope-map delete |
刪除 Azure Container Registry 的範圍對應。 |
Core | GA |
az acr scope-map list |
列出 Azure Container Registry 的所有範圍對應。 |
Core | GA |
az acr scope-map show |
顯示 Azure Container Registry 範圍對應的詳細數據和屬性。 |
Core | GA |
az acr scope-map update |
更新 Azure Container Registry 的範圍對應。 |
Core | GA |
az acr show |
取得 Azure Container Registry 的詳細數據。 |
Core | GA |
az acr show-endpoints |
顯示登錄端點。 |
Core | GA |
az acr show-usage |
取得 Azure Container Registry 的記憶體使用量。 |
Core | GA |
az acr supply-chain |
管理 acr 供應鏈資源的命令。 |
Extension | Preview |
az acr supply-chain workflow |
管理 acr 供應鏈工作流程的命令。 |
Extension | Preview |
az acr supply-chain workflow cancel-run |
取消目前正在執行的供應鏈工作流程。 |
Extension | Preview |
az acr supply-chain workflow create |
建立 acr 供應鏈工作流程。 |
Extension | Preview |
az acr supply-chain workflow delete |
刪除 acr 供應鏈工作流程。 |
Extension | Preview |
az acr supply-chain workflow list |
acr 供應鏈工作流程映像的清單狀態。 |
Extension | Preview |
az acr supply-chain workflow show |
顯示 acr 供應鏈工作流程工作。 |
Extension | Preview |
az acr supply-chain workflow update |
更新 acr 供應鏈工作流程。 |
Extension | Preview |
az acr task |
使用 Azure 容器登錄管理建置、測試和 OS 和架構修補容器映像的步驟集合。 |
Core | GA |
az acr task cancel-run |
取消 Azure Container Registry 的指定執行。 |
Core | GA |
az acr task create |
建立建置、測試和OS和架構修補容器的一系列步驟。 工作支援 Git 認可和基底映射更新的觸發程式。 |
Core | GA |
az acr task credential |
管理工作的認證。 如需詳細資訊,請參閱 https://aka.ms/acr/connected-registry 。 |
Core | GA |
az acr task credential add |
將自訂登錄登入認證新增至工作。 |
Core | GA |
az acr task credential list |
列出工作的所有自定義登錄認證。 |
Core | GA |
az acr task credential remove |
拿掉工作的認證。 |
Core | GA |
az acr task credential update |
更新工作的登錄登入認證。 |
Core | GA |
az acr task delete |
從 Azure Container Registry 刪除工作。 |
Core | GA |
az acr task identity |
工作的受控識別。 如需詳細資訊,請參閱 https://aka.ms/acr/connected-registry 。 |
Core | GA |
az acr task identity assign |
更新工作的受控識別。 |
Core | GA |
az acr task identity remove |
拿掉工作的受控識別。 |
Core | GA |
az acr task identity show |
顯示工作的受控識別。 |
Core | GA |
az acr task list |
列出 Azure Container Registry 的工作。 |
Core | GA |
az acr task list-runs |
列出 Azure Container Registry 執行的所有執行,並能夠依特定工作進行篩選。 |
Core | GA |
az acr task logs |
顯示特定執行的記錄。 如果未提供任何 run-id,則顯示上次建立回合的記錄。 |
Core | GA |
az acr task run |
手動觸發可能正在等候 Git 認可或基底映像更新觸發程式的工作。 |
Core | GA |
az acr task show |
取得 Azure Container Registry 具名工作的屬性。 |
Core | GA |
az acr task show-run |
取得指定之 Azure Container Registry 工作執行的屬性。 |
Core | GA |
az acr task timer |
管理工作的定時器觸發程式。 |
Core | GA |
az acr task timer add |
將定時器觸發程式新增至工作。 |
Core | GA |
az acr task timer list |
列出工作的所有定時器觸發程式。 |
Core | GA |
az acr task timer remove |
從工作中移除定時器觸發程式。 |
Core | GA |
az acr task timer update |
更新工作的定時器觸發程式。 |
Core | GA |
az acr task update |
更新 Azure Container Registry 的工作。 |
Core | GA |
az acr task update-run |
修補 Azure Container Registry 工作的執行屬性。 |
Core | GA |
az acr taskrun |
使用 Azure Container Registries 管理工作執行。 |
Core | Preview |
az acr taskrun delete |
從 Azure Container Registry 刪除工作執行。 |
Core | Preview |
az acr taskrun list |
列出 Azure Container Registry 的工作執行。 |
Core | Preview |
az acr taskrun logs |
顯示特定工作回合的執行記錄。 |
Core | Preview |
az acr taskrun show |
取得 Azure Container Registry 具名工作執行的屬性。 |
Core | Preview |
az acr token |
管理 Azure Container Registry 的令牌。 |
Core | GA |
az acr token create |
建立與 Azure Container Registry 範圍對應相關聯的令牌。 |
Core | GA |
az acr token credential |
管理 Azure Container Registry 令牌的認證。 |
Core | GA |
az acr token credential delete |
刪除令牌認證。 |
Core | GA |
az acr token credential generate |
產生或取代 Azure Container Registry 令牌的一或兩個密碼。 如需使用權杖和密碼來存取容器登錄,請參閱 https://aka.ms/acr/repo-permissions。 |
Core | GA |
az acr token delete |
刪除 Azure Container Registry 的令牌。 |
Core | GA |
az acr token list |
列出 Azure Container Registry 的所有令牌。 |
Core | GA |
az acr token show |
顯示 Azure Container Registry 令牌的詳細數據和屬性。 |
Core | GA |
az acr token update |
更新 Azure Container Registry 的令牌(取代相關聯的範圍對應)。 |
Core | GA |
az acr update |
更新 Azure Container Registry。 |
Core | GA |
az acr webhook |
管理 Azure 容器登錄的 Webhook。 |
Core | GA |
az acr webhook create |
建立 Azure Container Registry 的 Webhook。 |
Core | GA |
az acr webhook delete |
從 Azure Container Registry 刪除 Webhook。 |
Core | GA |
az acr webhook get-config |
取得 Webhook 的服務 URI 和自定義標頭。 |
Core | GA |
az acr webhook list |
列出 Azure Container Registry 的所有 Webhook。 |
Core | GA |
az acr webhook list-events |
列出 Webhook 的最新事件。 |
Core | GA |
az acr webhook ping |
觸發 Webhook 的 Ping 事件。 |
Core | GA |
az acr webhook show |
取得 Webhook 的詳細數據。 |
Core | GA |
az acr webhook update |
更新 Webhook。 |
Core | GA |
az acr build
將快速建置排入佇列,為 Azure Container Registry 提供串流記錄。
az acr build --registry
[--agent-pool]
[--auth-mode {Default, None}]
[--build-arg]
[--file]
[--image]
[--log-template]
[--no-format]
[--no-logs]
[--no-push]
[--no-wait]
[--platform]
[--resource-group]
[--secret-build-arg]
[--source-acr-auth-id {[caller], none}]
[--target]
[--timeout]
[]
範例
將本機內容排入佇列,作為 Linux 組建、標記它,並將它推送至登錄。
az acr build -t sample/hello-world:{{.Run.ID}} -r myregistry .
將本機內容排入佇列,作為 Linux 組建、標記,並將它推送至登錄,而不需要串流記錄。
az acr build -t sample/hello-world:{{.Run.ID}} -r myregistry --no-logs .
將本機內容排入佇列作為 Linux 組建,而不將其推送至登錄。
az acr build -t sample/hello-world:{{.Run.ID}} -r myregistry --no-push .
將本機內容排入佇列作為 Linux 組建,而不將其推送至登錄。
az acr build -r myregistry .
將遠端 GitHub 內容排入佇列,作為 Windows 組建、標記並推送至登錄。
az acr build -r myregistry https://github.com/Azure/acr-builder.git -f Windows.Dockerfile --platform windows
將遠端 OCI 成品內容組建排入佇列。
az acr build -r myregistry oci://myregistry.azurecr.io/myartifact:mytag
將本機內容排入佇列,作為 arm/v7 架構上的 Linux 組建、標記它,並將它推送至登錄。
az acr build -t sample/hello-world:{{.Run.ID}} -r myregistry . --platform linux/arm/v7
將本機內容排入佇列作為 Linux 組建、標記,並將其推送至已啟用 ABAC 的存放庫許可權登錄,並使用呼叫端的 Entra 身分識別向來源登錄進行驗證。
az acr build -t sample/hello-world:{{.Run.ID}} -r myregistry . --source-acr-auth-id [caller]
必要參數
容器登錄的名稱。 它應該以小寫指定。 您可以使用 az configure --defaults acr=<registry name>
來設定預設登錄名稱。
選擇性參數
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
代理程式集區的名稱。
來源登錄的驗證模式。
屬性 | 值 |
---|---|
接受的值: | Default, None |
'--build-arg name[=value]' 格式的組建自變數。 多次傳遞 '--build-arg name[=value]' 支援多個 。 重要:此參數不應包含任何種類的密碼、存取令牌或敏感性資訊。 ACR 小組將會看見此參數值以供偵錯之用。
docker 檔案到原始程式碼根資料夾的相對路徑。 默認為 『Dockerfile』。
影像的名稱和標記,其格式為:『-t 存放庫/image:tag』。 傳遞 -t 多次支援多個標記。
使用 'log/repo:tag' 格式執行記錄成品的存放庫和標記範本(例如 'acr/logs:{{.Run.ID}}')。 僅適用於已啟用 CMK 的登錄。
指出記錄是否應該以原始格式顯示。
屬性 | 值 |
---|---|
預設值: | False |
成功佇列組建之後,請勿顯示記錄。
屬性 | 值 |
---|---|
預設值: | False |
指出建置的映像是否應該推送至登錄。
屬性 | 值 |
---|---|
預設值: | False |
請勿等候組建完成,並在佇列建置之後立即返回。
屬性 | 值 |
---|---|
預設值: | False |
執行建置/工作的平臺,例如'windows' 和 'linux'。 在建置命令中使用時,也可以針對產生的影像指定 『os/arch/variant』 格式。 Eg, linux/arm/v7. 'arch' 和 'variant' 元件是選擇性的。
資源組名。 您可以使用 az configure --defaults group=<name>
來設定預設群組。
'--secret-build-arg name[=value]' 格式的秘密建置自變數。 多次傳遞 '--secret-build-arg name[=value]' 支援多個 。 此參數值不會浮出給 ACR 小組,而且更適合敏感性資訊。
指派用於來源登錄登入的身分識別。 使用 '[caller]' 進行呼叫端身分識別。
屬性 | 值 |
---|---|
接受的值: | [caller], none |
目標建置階段的名稱。
以秒為單位的逾時。
本機原始程式碼目錄路徑(例如 './src'),或 Git 存放庫的 URL(例如'https://github.com/Azure-Samples/acr-build-helloworld-node.git')或遠端 tarball(例如''http://server/context.tar.gz),或 Azure 容器登錄中 OCI 成品的存放庫(例如 'oci://myregistry.azurecr.io/myartifact:mytag')。
屬性 | 值 |
---|---|
Parameter group: | Positional |
全域參數
提高日誌詳細程度以顯示所有調試日誌。
屬性 | 值 |
---|---|
預設值: | False |
顯示此說明訊息並結束。
只顯示錯誤,隱藏警告。
屬性 | 值 |
---|---|
預設值: | False |
Output format.
屬性 | 值 |
---|---|
預設值: | json |
接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/。
訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID
來設定預設訂用帳戶。
增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。
屬性 | 值 |
---|---|
預設值: | False |
az acr check-health
取得環境的健康情況資訊,並選擇性地取得目標登錄。
az acr check-health [--ignore-errors]
[--name]
[--repository]
[--vnet]
[--yes]
範例
取得目標登錄 'myregistry' 的健康狀態,略過提取映射的確認。
az acr check-health -n myregistry -y
取得環境的健全狀態,而不會在第一次錯誤時停止。
az acr check-health --ignore-errors
取得目標登錄 『myregistry』 的健康狀態,並檢查特定存放庫 『myrepo』 的允許許可權。
az acr check-health -n myregistry --repository myrepo
選擇性參數
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
提供所有健康情況檢查,即使找到錯誤也一樣。
屬性 | 值 |
---|---|
預設值: | False |
容器登錄的名稱。 它應該以小寫指定。 您可以使用 az configure --defaults acr=<registry name>
來設定預設登錄名稱。
存放庫的名稱。
虛擬網路識別碼,以便在 VNET 內執行此命令,以驗證 DNS 路由至私人端點。
請勿提示確認。
屬性 | 值 |
---|---|
預設值: | False |
全域參數
提高日誌詳細程度以顯示所有調試日誌。
屬性 | 值 |
---|---|
預設值: | False |
顯示此說明訊息並結束。
只顯示錯誤,隱藏警告。
屬性 | 值 |
---|---|
預設值: | False |
Output format.
屬性 | 值 |
---|---|
預設值: | json |
接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/。
訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID
來設定預設訂用帳戶。
增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。
屬性 | 值 |
---|---|
預設值: | False |
az acr check-name
檢查 Azure Container Registry 名稱是否有效且可供使用。
az acr check-name --name
[--dnl-scope {NoReuse, ResourceGroupReuse, SubscriptionReuse, TenantReuse, Unsecure}]
[--resource-group]
範例
檢查登錄名稱是否存在。
az acr check-name -n doesthisnameexist
必要參數
容器登錄的名稱。 它應該以小寫指定。 您可以使用 az configure --defaults acr=<registry name>
來設定預設登錄名稱。
選擇性參數
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
Domain name label 範圍將向資源名稱添加哈希值。 生成的登錄伺服器名稱將採用 .azurecr-io 格式 registry-name
-hash
。 預設值為 Unsecure。
屬性 | 值 |
---|---|
預設值: | Unsecure |
接受的值: | NoReuse, ResourceGroupReuse, SubscriptionReuse, TenantReuse, Unsecure |
資源組名。 您可以使用 az configure --defaults group=<name>
來設定預設群組。
全域參數
提高日誌詳細程度以顯示所有調試日誌。
屬性 | 值 |
---|---|
預設值: | False |
顯示此說明訊息並結束。
只顯示錯誤,隱藏警告。
屬性 | 值 |
---|---|
預設值: | False |
Output format.
屬性 | 值 |
---|---|
預設值: | json |
接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/。
訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID
來設定預設訂用帳戶。
增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。
屬性 | 值 |
---|---|
預設值: | False |
az acr create
建立 Azure Container Registry。
az acr create --name
--resource-group
--sku {Basic, Premium, Standard}
[--admin-enabled {false, true}]
[--allow-exports {false, true}]
[--allow-metadata-search {false, true}]
[--allow-trusted-services {false, true}]
[--default-action {Allow, Deny}]
[--dnl-scope {NoReuse, ResourceGroupReuse, SubscriptionReuse, TenantReuse, Unsecure}]
[--identity]
[--key-encryption-key]
[--location]
[--public-network-enabled {false, true}]
[--role-assignment-mode {rbac, rbac-abac}]
[--tags]
[--workspace]
[--zone-redundancy {Disabled, Enabled}]
範例
使用標準 SKU 建立受控容器登錄。
az acr create -n myregistry -g MyResourceGroup --sku Standard
建立已啟用 ABAC 型存放庫許可權的登錄。
az acr create -n myregistry -g MyResourceGroup --sku Standard --role-assignment-mode rbac-abac
必要參數
容器登錄的名稱。 它應該以小寫指定。 您可以使用 az configure --defaults acr=<registry name>
來設定預設登錄名稱。
資源組名。 您可以使用 az configure --defaults group=<name>
來設定預設群組。
容器登錄的SKU。
屬性 | 值 |
---|---|
接受的值: | Basic, Premium, Standard |
選擇性參數
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
指出是否啟用系統管理員使用者。
屬性 | 值 |
---|---|
預設值: | False |
接受的值: | false, true |
設定 exportPolicy 以允許/不允許從此登錄匯出成品。 成品可以透過匯入或傳輸作業導出。 如需詳細資訊,請造訪 https://aka.ms/acr/export-policy。
屬性 | 值 |
---|---|
接受的值: | false, true |
啟用或停用登錄的元數據搜尋功能。 如果未指定,則預設會設定為停用。
屬性 | 值 |
---|---|
接受的值: | false, true |
允許受信任的 Azure 服務存取網路限制的登錄。 如需詳細資訊,請造訪 https://aka.ms/acr/export-policy。 [預設值] 是允許的。
屬性 | 值 |
---|---|
Parameter group: | Network Rule Arguments |
接受的值: | false, true |
未符合規則時要套用的預設動作。 僅適用於進階 SKU。
屬性 | 值 |
---|---|
Parameter group: | Network Rule Arguments |
接受的值: | Allow, Deny |
Domain name label 範圍會給資源名稱添加一個哈希值。 生成的登錄伺服器名稱將採用 .azurecr-io 格式 registryname
-hash
。 預設值為 Unsecure。
屬性 | 值 |
---|---|
接受的值: | NoReuse, ResourceGroupReuse, SubscriptionReuse, TenantReuse, Unsecure |
如果在相同的資源群組中,請使用指派的受控識別資源標識碼或名稱。
屬性 | 值 |
---|---|
Parameter group: | Customer managed key Arguments |
金鑰儲存庫金鑰 URI。 若要啟用自動輪替,請提供無版本密鑰 URI。 針對手動輪替,請提供已建立版本的密鑰 URI。
屬性 | 值 |
---|---|
Parameter group: | Customer managed key Arguments |
Location. 值的來源:az account list-locations
。 您可以使用 az configure --defaults location=<location>
來設定預設位置。
允許容器登錄的公用網路存取。 [預設值] 是允許的。
屬性 | 值 |
---|---|
Parameter group: | Network Rule Arguments |
接受的值: | false, true |
登錄的角色指派模式。 如需這項功能的詳細資訊,請參閱 https://aka.ms/acr/auth/abac。 預設值為 rbac。
屬性 | 值 |
---|---|
Parameter group: | Permissions and Role Assignment Arguments |
接受的值: | rbac, rbac-abac |
以空格分隔的標記:key[=value] [key[=value] ...]。使用 「清除現有的標記」。
要傳送登錄診斷記錄的Log Analytics工作區名稱或標識碼。 所有事件都會啟用。 您可以使用 “az monitor log-analytics workspace create” 來建立一個。 可能會套用額外的計費。
指出是否應該為此登錄或復寫啟用區域備援。 如需詳細資訊,例如支援的位置,請造訪 https://aka.ms/acr/az。 區域備援無法更新。 預設為 『Disabled』。
屬性 | 值 |
---|---|
接受的值: | Disabled, Enabled |
全域參數
提高日誌詳細程度以顯示所有調試日誌。
屬性 | 值 |
---|---|
預設值: | False |
顯示此說明訊息並結束。
只顯示錯誤,隱藏警告。
屬性 | 值 |
---|---|
預設值: | False |
Output format.
屬性 | 值 |
---|---|
預設值: | json |
接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/。
訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID
來設定預設訂用帳戶。
增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。
屬性 | 值 |
---|---|
預設值: | False |
az acr delete
刪除 Azure Container Registry。
az acr delete --name
[--resource-group]
[--yes]
範例
刪除 Azure Container Registry。
az acr delete -n myregistry
必要參數
容器登錄的名稱。 它應該以小寫指定。 您可以使用 az configure --defaults acr=<registry name>
來設定預設登錄名稱。
選擇性參數
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
資源組名。 您可以使用 az configure --defaults group=<name>
來設定預設群組。
請勿提示確認。
屬性 | 值 |
---|---|
預設值: | False |
全域參數
提高日誌詳細程度以顯示所有調試日誌。
屬性 | 值 |
---|---|
預設值: | False |
顯示此說明訊息並結束。
只顯示錯誤,隱藏警告。
屬性 | 值 |
---|---|
預設值: | False |
Output format.
屬性 | 值 |
---|---|
預設值: | json |
接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/。
訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID
來設定預設訂用帳戶。
增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。
屬性 | 值 |
---|---|
預設值: | False |
az acr import
從另一個 Container Registry 將映射匯入至 Azure Container Registry。 匯入會移除 docker pull、docker tag、docker push 的需求。 對於較大的影像,請考慮使用 --no-wait
。
az acr import --name
--source
[--force]
[--image]
[--no-wait]
[--password]
[--registry]
[--repository]
[--resource-group]
[--username]
範例
將影像從 'sourceregistry' 匯入 'myregistry'。 映射會繼承其來源存放庫和標記名稱。
az acr import -n myregistry --source sourceregistry.azurecr.io/sourcerepository:sourcetag
從 Docker Hub 上的公用存放庫匯入映像。 映像會使用指定的存放庫和標記名稱。
az acr import -n myregistry --source docker.io/library/hello-world:latest -t targetrepository:targettag
使用其使用者名稱和密碼,從私人存放庫匯入映像。 這也適用於 Azure 外部的登錄。
az acr import -n myregistry --source myprivateregistry.azurecr.io/hello-world:latest -u username -p password
從不同訂用帳戶中的 Azure 容器登錄匯入映像。
az acr import -n myregistry --source sourcerepository:sourcetag -t targetrepository:targettag \
-r /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/sourceResourceGroup/providers/Microsoft.ContainerRegistry/registries/sourceRegistry
匯入映像,而不需等待成功完成。 匯入期間的失敗將不會反映。 執行 'az acr repository show-tags' 以確認匯入成功。
az acr import -n myregistry --source sourceregistry.azurecr.io/sourcerepository:sourcetag --no-wait
必要參數
容器登錄的名稱。 它應該以小寫指定。 您可以使用 az configure --defaults acr=<registry name>
來設定預設登錄名稱。
包含登錄登入伺服器的來源映像名稱或完整來源。 如果使用 --registry
, --source
則一律會解譯為來源映像,即使它包含登入伺服器也一樣。
選擇性參數
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
覆寫要匯入之映像的現有標記。
屬性 | 值 |
---|---|
預設值: | False |
影像的名稱和標記,其格式為:『-t 存放庫/image:tag』。 傳遞 -t 多次支援多個標記。
請勿等候匯入完成,並在匯入佇列后立即返回。
屬性 | 值 |
---|---|
預設值: | False |
來源容器登錄的密碼。
來源 Azure 容器登錄。 這可以是來源登錄的名稱、登入伺服器或資源標識符。
僅限指令清單映像複本的存放庫名稱。 傳遞 --repository 多次支援多個複本。
資源組名。 您可以使用 az configure --defaults group=<name>
來設定預設群組。
來源容器登錄的用戶名稱。
全域參數
提高日誌詳細程度以顯示所有調試日誌。
屬性 | 值 |
---|---|
預設值: | False |
顯示此說明訊息並結束。
只顯示錯誤,隱藏警告。
屬性 | 值 |
---|---|
預設值: | False |
Output format.
屬性 | 值 |
---|---|
預設值: | json |
接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/。
訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID
來設定預設訂用帳戶。
增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。
屬性 | 值 |
---|---|
預設值: | False |
az acr list
列出目前訂用帳戶下的所有容器登錄。
az acr list [--resource-group]
範例
列出容器登錄,並在多個資源群組的數據表中顯示結果。
az acr list -o table
列出資源群組中的容器登錄,並在數據表中顯示結果。
az acr list -g MyResourceGroup -o table
選擇性參數
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
資源組名。 您可以使用 az configure --defaults group=<name>
來設定預設群組。
全域參數
提高日誌詳細程度以顯示所有調試日誌。
屬性 | 值 |
---|---|
預設值: | False |
顯示此說明訊息並結束。
只顯示錯誤,隱藏警告。
屬性 | 值 |
---|---|
預設值: | False |
Output format.
屬性 | 值 |
---|---|
預設值: | json |
接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/。
訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID
來設定預設訂用帳戶。
增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。
屬性 | 值 |
---|---|
預設值: | False |
az acr login
透過 Docker CLI 登入 Azure Container Registry。
Docker 必須安裝在您的電腦上。 完成後,請使用 docker logout <registry url>
來註銷。(如果您只需要重新整理令牌,而且不想安裝 Docker,請指定 '--public-token')。
az acr login --name
[--expose-token]
[--password]
[--resource-group]
[--suffix]
[--username]
範例
登入 Azure Container Registry
az acr login -n myregistry
取得 Azure Container Registry 存取令牌
az acr login -n myregistry --expose-token
必要參數
容器登錄的名稱。 它應該以小寫指定。 您可以使用 az configure --defaults acr=<registry name>
來設定預設登錄名稱。
選擇性參數
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
公開重新整理令牌,而不是透過 Docker CLI 自動登入。
屬性 | 值 |
---|---|
預設值: | False |
用來登入容器登錄的密碼。
資源組名。 您可以使用 az configure --defaults group=<name>
來設定預設群組。
登錄登入伺服器中的租用戶後綴。 如果您的登錄登入伺服器格式為 『registry-tenant.azurecr.io』,您可以指定 '--suffix tenant'。 適用於您從不同的訂用帳戶存取登錄,或您有權存取映射,但無權管理登錄資源。
用來登入容器登錄的用戶名稱。
全域參數
提高日誌詳細程度以顯示所有調試日誌。
屬性 | 值 |
---|---|
預設值: | False |
顯示此說明訊息並結束。
只顯示錯誤,隱藏警告。
屬性 | 值 |
---|---|
預設值: | False |
Output format.
屬性 | 值 |
---|---|
預設值: | json |
接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/。
訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID
來設定預設訂用帳戶。
增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。
屬性 | 值 |
---|---|
預設值: | False |
az acr query
使用 Kusto 查詢語言查詢 ACR 中的內容。
使用 Kusto 查詢語言查詢 Azure Container Registry 中的成品和映像。 OCI 指令清單屬性,例如摘要、主旨、註釋等,可用來查詢、篩選及排序搜尋結果。
az acr query --kql-query
--name
[--password]
[--repository]
[--skip-token]
[--username]
範例
擷取單一指令清單
az acr query -n $MyRegistry -q "Manifests | limit 1"
計算存放庫中的所有指令清單$RepositoryName
az acr query -n $MyRegistry -q "Manifests" -o table
依建立日期的順序列出存放庫$RepositoryName中的所有指令清單
az acr query -n $MyRegistry --repository $RepositoryName -q "Manifests | order by createdAt desc"
查詢存放庫中$Signature所簽署的所有摘要$RepositoryName
az acr query -n $MyRegistry --repository $RepositoryName -q "Manifests | where annotations['org.cncf.notary.signature.subject'] == $Signature | project createdAt, digest, subject"
使用略過權杖查詢登錄的摘要並依摘要排序(針對具有分頁的結果)
az acr query -n $MyRegistry -q "Manifests | project digest | order by digest asc" --skip-token eyAibm8iOiAibHVjayIsICJidXQiOiAibmljZSIsICJ0cnkiOiAiISIgfQ==
必要參數
要執行的 KQL 查詢。
執行查詢的容器登錄名稱。
選擇性參數
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
Registry password.
執行查詢的存放庫。 如果未提供存放庫,查詢就會在登錄層級執行。
如果適用的話,請略過令牌以取得查詢的下一頁。
Registry username.
全域參數
提高日誌詳細程度以顯示所有調試日誌。
屬性 | 值 |
---|---|
預設值: | False |
顯示此說明訊息並結束。
只顯示錯誤,隱藏警告。
屬性 | 值 |
---|---|
預設值: | False |
Output format.
屬性 | 值 |
---|---|
預設值: | json |
接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/。
訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID
來設定預設訂用帳戶。
增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。
屬性 | 值 |
---|---|
預設值: | False |
az acr run
將快速執行排入佇列,以提供 Azure Container Registry 的串流記錄。
az acr run --registry
[--agent-pool]
[--auth-mode {Default, None}]
[--cmd]
[--file]
[--log-template]
[--no-format]
[--no-logs]
[--no-wait]
[--platform]
[--resource-group]
[--set]
[--set-secret]
[--source-acr-auth-id {[caller], none}]
[--timeout]
[--values]
[]
範例
將執行排入佇列以執行容器命令。
az acr run -r myregistry --cmd '$Registry/myimage' /dev/null
使用標準輸入的工作定義,將執行排入佇列。 'Ctrl + Z'(Windows) 或 'Ctrl + D'(Linux) 會終止輸入數據流。
az acr run -r myregistry -f - /dev/null
將執行排入佇列,以執行透過管道傳遞的工作。
cat task.yaml | az acr run -r myregistry -f - /dev/null
將本機內容排入佇列,並推送至具有串流記錄的 ACR。
az acr run -r myregistry -f bash-echo.yaml ./workspace
使用串流記錄將遠端 Git 內容排入佇列。
az acr run -r myregistry https://github.com/Azure-Samples/acr-tasks.git -f hello-world.yaml
使用串流記錄將遠端 Git 內容排入佇列,並在 Linux 平台上執行工作。
az acr run -r myregistry https://github.com/Azure-Samples/acr-tasks.git -f build-hello-world.yaml --platform linux
將遠端 OCI 成品內容排入佇列,並執行工作。
az acr run -r myregistry oci://myregistry.azurecr.io/myartifact:mytag -f hello-world.yaml
將執行排入佇列,以在已啟用 ABAC 的存放庫許可權登錄中執行容器命令,並使用呼叫端的 Entra 身分識別向來源登錄進行驗證。
az acr run -r myregistry --cmd '$Registry/myimage' /dev/null --source-acr-auth-id [caller]
必要參數
容器登錄的名稱。 它應該以小寫指定。 您可以使用 az configure --defaults acr=<registry name>
來設定預設登錄名稱。
選擇性參數
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
代理程式集區的名稱。
來源登錄的驗證模式。
屬性 | 值 |
---|---|
接受的值: | Default, None |
要執行的命令。 這也支援其他 Docker 執行參數 (https://docs.docker.com/engine/reference/commandline/run/) 或甚至其他 Docker 命令 (https://docs.docker.com/engine/reference/commandline/docker/)。
相對於來源內容的工作範本/定義檔案路徑。 從標準輸入傳送檔案可以是 『-』。
使用 'log/repo:tag' 格式執行記錄成品的存放庫和標記範本(例如 'acr/logs:{{.Run.ID}}')。 僅適用於已啟用 CMK 的登錄。
指出記錄是否應該以原始格式顯示。
屬性 | 值 |
---|---|
預設值: | False |
成功佇列組建之後,請勿顯示記錄。
屬性 | 值 |
---|---|
預設值: | False |
請勿等候執行完成,並在佇列執行之後立即返回。
屬性 | 值 |
---|---|
預設值: | False |
執行建置/工作的平臺,例如'windows' 和 'linux'。 在建置命令中使用時,也可以針對產生的影像指定 『os/arch/variant』 格式。 Eg, linux/arm/v7. 'arch' 和 'variant' 元件是選擇性的。
資源組名。 您可以使用 az configure --defaults group=<name>
來設定預設群組。
'name[=value]' 格式的值。 傳遞 --set 多次來支援的倍數。
'--set name[=value]' 格式的秘密值。 傳遞 --set 多次來支援的倍數。
指派用於來源登錄登入的身分識別。 使用 '[caller]' 進行呼叫端身分識別。
屬性 | 值 |
---|---|
接受的值: | [caller], none |
以秒為單位的逾時。
工作值相對於來源內容的檔案路徑。
本機原始程式碼目錄路徑(例如 './src'),或 Git 存放庫的 URL(例如''),或遠端 tarball(https://github.com/Azure-Samples/acr-build-helloworld-node.git例如''http://server/context.tar.gz)或 Azure 容器登錄中 OCI 成品的存放庫(例如 'oci://myregistry.azurecr.io/myartifact:mytag')。 如果指定 『/dev/null』,則值會設定為 None 並忽略。
屬性 | 值 |
---|---|
Parameter group: | Positional |
全域參數
提高日誌詳細程度以顯示所有調試日誌。
屬性 | 值 |
---|---|
預設值: | False |
顯示此說明訊息並結束。
只顯示錯誤,隱藏警告。
屬性 | 值 |
---|---|
預設值: | False |
Output format.
屬性 | 值 |
---|---|
預設值: | json |
接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/。
訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID
來設定預設訂用帳戶。
增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。
屬性 | 值 |
---|---|
預設值: | False |
az acr show
取得 Azure Container Registry 的詳細數據。
az acr show --name
[--resource-group]
範例
取得 Azure Container Registry 的登入伺服器。
az acr show -n myregistry --query loginServer
取得 Azure Container Registry 的詳細數據
az acr show --name myregistry --resource-group MyResourceGroup
檢查登錄上ABAC型存放庫許可權的狀態。
az acr show --name myregistry --resource-group MyResourceGroup --query roleAssignmentMode
必要參數
容器登錄的名稱。 它應該以小寫指定。 您可以使用 az configure --defaults acr=<registry name>
來設定預設登錄名稱。
選擇性參數
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
資源組名。 您可以使用 az configure --defaults group=<name>
來設定預設群組。
全域參數
提高日誌詳細程度以顯示所有調試日誌。
屬性 | 值 |
---|---|
預設值: | False |
顯示此說明訊息並結束。
只顯示錯誤,隱藏警告。
屬性 | 值 |
---|---|
預設值: | False |
Output format.
屬性 | 值 |
---|---|
預設值: | json |
接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/。
訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID
來設定預設訂用帳戶。
增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。
屬性 | 值 |
---|---|
預設值: | False |
az acr show-endpoints
顯示登錄端點。
az acr show-endpoints --name
[--resource-group]
必要參數
容器登錄的名稱。 它應該以小寫指定。 您可以使用 az configure --defaults acr=<registry name>
來設定預設登錄名稱。
選擇性參數
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
資源組名。 您可以使用 az configure --defaults group=<name>
來設定預設群組。
全域參數
提高日誌詳細程度以顯示所有調試日誌。
屬性 | 值 |
---|---|
預設值: | False |
顯示此說明訊息並結束。
只顯示錯誤,隱藏警告。
屬性 | 值 |
---|---|
預設值: | False |
Output format.
屬性 | 值 |
---|---|
預設值: | json |
接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/。
訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID
來設定預設訂用帳戶。
增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。
屬性 | 值 |
---|---|
預設值: | False |
az acr show-usage
取得 Azure Container Registry 的記憶體使用量。
az acr show-usage --name
[--resource-group]
範例
取得 Azure Container Registry 的記憶體使用量。
az acr show-usage -n myregistry
必要參數
容器登錄的名稱。 它應該以小寫指定。 您可以使用 az configure --defaults acr=<registry name>
來設定預設登錄名稱。
選擇性參數
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
資源組名。 您可以使用 az configure --defaults group=<name>
來設定預設群組。
全域參數
提高日誌詳細程度以顯示所有調試日誌。
屬性 | 值 |
---|---|
預設值: | False |
顯示此說明訊息並結束。
只顯示錯誤,隱藏警告。
屬性 | 值 |
---|---|
預設值: | False |
Output format.
屬性 | 值 |
---|---|
預設值: | json |
接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/。
訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID
來設定預設訂用帳戶。
增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。
屬性 | 值 |
---|---|
預設值: | False |
az acr update
更新 Azure Container Registry。
az acr update --name
[--add]
[--admin-enabled {false, true}]
[--allow-exports {false, true}]
[--allow-metadata-search {false, true}]
[--allow-trusted-services {false, true}]
[--anonymous-pull-enabled {false, true}]
[--data-endpoint-enabled {false, true}]
[--default-action {Allow, Deny}]
[--force-string]
[--public-network-enabled {false, true}]
[--remove]
[--resource-group]
[--role-assignment-mode {rbac, rbac-abac}]
[--set]
[--sku {Basic, Premium, Standard}]
[--tags]
範例
更新 Azure Container Registry 的標籤。
az acr update -n myregistry --tags key1=value1 key2=value2
啟用 Azure Container Registry 的系統管理員用戶帳戶。
az acr update -n myregistry --admin-enabled true
開啟現有登錄的 ABAC 型存放庫許可權。
az acr update -n myregistry --role-assignment-mode rbac-abac
必要參數
容器登錄的名稱。 它應該以小寫指定。 您可以使用 az configure --defaults acr=<registry name>
來設定預設登錄名稱。
選擇性參數
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
藉由指定路徑和索引鍵值組,將物件加入物件清單。 範例: --add property.listProperty <key=value, string or JSON string>
.
屬性 | 值 |
---|---|
Parameter group: | Generic Update Arguments |
預設值: | [] |
指出是否啟用系統管理員使用者。
屬性 | 值 |
---|---|
接受的值: | false, true |
設定 exportPolicy 以允許/不允許從此登錄匯出成品。 成品可以透過匯入或傳輸作業導出。 如需詳細資訊,請造訪 https://aka.ms/acr/export-policy。
屬性 | 值 |
---|---|
接受的值: | false, true |
啟用或停用登錄的元數據搜尋功能。
屬性 | 值 |
---|---|
接受的值: | false, true |
允許受信任的 Azure 服務存取網路限制的登錄。 如需詳細資訊,請造訪 https://aka.ms/acr/export-policy。
屬性 | 值 |
---|---|
Parameter group: | Network Rule Arguments |
接受的值: | false, true |
從未經驗證的用戶端啟用全登錄提取。
屬性 | 值 |
---|---|
接受的值: | false, true |
啟用用戶端防火牆設定的專用數據端點。
屬性 | 值 |
---|---|
Parameter group: | Network Rule Arguments |
接受的值: | false, true |
未符合規則時要套用的預設動作。 僅適用於進階 SKU。
屬性 | 值 |
---|---|
Parameter group: | Network Rule Arguments |
接受的值: | Allow, Deny |
使用 'set' 或 'add' 時,請保留字串常值,而不是嘗試轉換成 JSON。
屬性 | 值 |
---|---|
Parameter group: | Generic Update Arguments |
預設值: | False |
允許容器登錄的公用網路存取。
屬性 | 值 |
---|---|
Parameter group: | Network Rule Arguments |
接受的值: | false, true |
從清單中移除屬性或專案。 範例: --remove property.list <indexToRemove>
或 --remove propertyToRemove
。
屬性 | 值 |
---|---|
Parameter group: | Generic Update Arguments |
預設值: | [] |
資源組名。 您可以使用 az configure --defaults group=<name>
來設定預設群組。
登錄的角色指派模式。 如需這項功能的詳細資訊,請參閱 https://aka.ms/acr/auth/abac。 預設值為 rbac。
屬性 | 值 |
---|---|
Parameter group: | Permissions and Role Assignment Arguments |
接受的值: | rbac, rbac-abac |
指定要設定的屬性路徑和值,以更新物件。 範例: --set property1.property2=<value>
.
屬性 | 值 |
---|---|
Parameter group: | Generic Update Arguments |
預設值: | [] |
容器登錄的SKU。
屬性 | 值 |
---|---|
接受的值: | Basic, Premium, Standard |
以空格分隔的標記:key[=value] [key[=value] ...]。使用 「清除現有的標記」。
全域參數
提高日誌詳細程度以顯示所有調試日誌。
屬性 | 值 |
---|---|
預設值: | False |
顯示此說明訊息並結束。
只顯示錯誤,隱藏警告。
屬性 | 值 |
---|---|
預設值: | False |
Output format.
屬性 | 值 |
---|---|
預設值: | json |
接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/。
訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID
來設定預設訂用帳戶。
增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。
屬性 | 值 |
---|---|
預設值: | False |