question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Missing features in az ml environment CLIv2 that were present in v1

See original GitHub issue

Related command az ml environment create

Is your feature request related to a problem? Please describe. When creating an environment with a Docker image that is located in a private registry, there is no current way to authenticate with the private registry in the YAML configuration file. Trying to create the image results in an “Unauthorized” error message, as we are not able to pass in credentials.

Describe the solution you’d like In the Azure ML Python SDK v1, there is an option to define a private registry address as well as username and password. Here is the “fastai” demo code:

fastai_env.docker.base_image_registry.address = "myregistry.azurecr.io"
fastai_env.docker.base_image_registry.username = "username"
fastai_env.docker.base_image_registry.password = "password"

https://github.com/Azure/MachineLearningNotebooks/blob/master/how-to-use-azureml/ml-frameworks/fastai/fastai-with-custom-docker/fastai-with-custom-docker.ipynb

Please include options in the Environment YAML configuration (as well as the SDKv2) to match existing features in the Python SDK v1.

Describe alternatives you’ve considered As a work-around, we are currently using the SDK v1 to register the environment that uses a private registry. After the environment has been registered with v1, we can use the CLI v2 to perform training, model deployments, etc.

Additional context

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:7 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
tphilleycommented, Oct 18, 2022

Fantastic, thanks!

0reactions
singankitcommented, Oct 18, 2022

Unfortunately, the schemas for the credentials are not published. I will work with the team to publish them during upcoming release. Meanwhile sharing the schemas for credentials below:

PAT Credential Configuration

credentials:
  type: pat
  pat: dummy_pat

Username Password Credential Configuration

credentials:
  type: username_password
  username: dummy
  password: dummy

Managed Identity Credential Configuration

credentials:
  type: managed_identity
  client_id: client_id
  resource_id: resource_id

Service Principal Credentials Configuration

credentials:
  type: service_principal
  client_id: client_id
  client_secret: PasswordPlaceHolder
  tenant_id: tenant_id
Read more comments on GitHub >

github_iconTop Results From Across the Web

Manage Azure Machine Learning environments with the CLI ...
Learn how to manage Azure ML environments using Python SDK and Azure ... Custom environments are user-defined and can be created via az...
Read more >
Changes to `az ml environment` creation no longer allows for ...
However, in the new schema it appears that the key environmentVariables is no longer supported (as it once did here, for example). Previously...
Read more >
Environment | Azure Machine Learning
Guide to working with Python environments in Azure ML.
Read more >
Build Recap | Introduction to Azure ML CLI v2 and SDK v2
Bala Venkataraman is here to educate users about the Azure Machine Learning CLI v2 and Python SDK v2 - one of the exciting...
Read more >
Azure ML Studio: Clean Missing Data pill - YouTube
Data: https://www.kaggle.com/wordsforthewise/lending-club.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found