Closed sudospyro closed 3 months ago
@thedudetom Thanks for your feedback! We will investigate and update as appropriate.
I have now isolated this issue to when the component environment image lies inside the workspace acr: Note the distinction between ACR and registry. ACR represents the default ACR deployed in the workspace, registry represents the azureml registry resource.
To test this, I have created a new workspace, with a machine learning registry linked. Is there a permission I am missing?
Component definition:
$schema: https://azuremlschemas.azureedge.net/latest/commandComponent.schema.json
type: command
version: 1
name: dummy
display_name: dummy
code: ./code
inputs:
input1:
type: string
optional: true
environment:
image: WORKSPACE_ACR_NAME.azurecr.io/busybox:latest
command: >-
python -V
cred = AzureCliCredential()
reg_ml_client = MLClient(cred, registry_name=AZUREML_REGISTRY_NAME)
component = load_component(COMPONENT_PATH)
reg_ml_client.components.create_or_update(component)
@sudospyro Is your workspace in the same region? Also, could you please create a support ticket for this error and we can help investigate?
@sudospyro To gain a better understanding of your issue, I'd recommend working closer with our support team via an Azure support request.
Thanks @fkriti @Naveenommi-MSFT I have opened a support ticket. This issue was replicated in a new environment that was created via portal UI. All resources exist inside the same resource group, and region.
Error message returned from create_or_update()
azure.core.exceptions.HttpResponseError: (UserError) Authentication failed for container registry REGISTRY_NAME.azurecr.io
Code: UserError
Message: Authentication failed for container registry REGISTRY_NAME.azurecr.io
Running az acr login --name REGISTRY_NAME
makes no difference to this error.
@sudospyro This issue could be due to incorrect registry authentication credentials or a network connectivity problem between the environment and the container registry. Please verify both.
We are going to close this thread, if there are any further questions regarding the documentation, please tag me in your reply and we will be happy to continue the conversation.
Using SDK azure-ai-ml v1.16.0
MLClient keeps throwing HttpResponseError due to unauthorised registry access when instanciated via:
However I suspect this is due to the inability to configure the registry location.
My registry, obfuscated with REGISTRY_NAME, resides inside westeurope, however this is querying eastus. Registries are unique per location, hence I doubt it is looking in the right place.
I have seen #105457 references a registry paramater, however this does not work as the underlying SDK does not make use of this anymore.
Documentation might be out of date now - docs relates to sharing environments with registries.
How can I instantiate MLClient pointing to my registry inside a different region?
Document Details
⚠ Do not edit this section. It is required for learn.microsoft.com ➟ GitHub issue linking.