@@ -596,16 +596,16 @@ az ml connection create --file connection.yaml
596
596
597
597
# [ Python SDK] ( #tab/python )
598
598
599
- The following example creates an Azure Container Registry connection. A managed identity authenticates this connection :
599
+ The following example creates an Azure Container Registry connection:
600
600
601
601
``` python
602
602
from azure.ai.ml.entities import WorkspaceConnection
603
603
from azure.ai.ml.entities import UsernamePasswordConfiguration
604
604
605
605
# If using username/password, the name/password values should be url-encoded
606
606
import urllib.parse
607
- username = urllib.parse.quote( os.environ[" REGISTRY_USERNAME" ], safe = " " )
608
- password = urllib.parse.quote( os.environ[" REGISTRY_PASSWORD" ], safe = " " )
607
+ username = os.environ[" REGISTRY_USERNAME" ]
608
+ password = os.environ[" REGISTRY_PASSWORD" ]
609
609
610
610
name = " my_acr_conn"
611
611
@@ -717,7 +717,7 @@ az ml environment show --name my-env --version 1 --resource-group my-resource-gr
717
717
718
718
# [ Python SDK] ( #tab/python )
719
719
720
- The following example creates an Azure Container Registry connection. A managed identity authenticates this connection:
720
+ The following example creates a Generic Container Registry connection:
721
721
722
722
``` python
723
723
import os
@@ -729,10 +729,8 @@ from azure.ai.ml.entities import UsernamePasswordConfiguration
729
729
from azureml.core.conda_dependencies import CondaDependencies
730
730
from azure.ai.ml import command
731
731
732
- # If using username/password, the name/password values should be url-encoded
733
- import urllib.parse
734
- username = urllib.parse.quote(os.environ[" REGISTRY_USERNAME" ], safe = " " )
735
- password = urllib.parse.quote(os.environ[" REGISTRY_PASSWORD" ], safe = " " )
732
+ username = os.environ[" REGISTRY_USERNAME" ]
733
+ password = os.environ[" REGISTRY_PASSWORD" ]
736
734
737
735
# Enter details of AML workspace
738
736
subscription_id = " <SUBSCRIPTION_ID>"
0 commit comments