Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AutoPR machinelearningservices] Add descriptions to mfe.json 2021-03-01-preview #1934

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions src/machinelearningservices/HISTORY.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
.. :changelog:

Release History
===============

0.1.0
++++++
* Initial release.
255 changes: 255 additions & 0 deletions src/machinelearningservices/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,255 @@
# Azure CLI machinelearningservices Extension #
This is the extension for machinelearningservices

### How to use ###
Install this extension using the below CLI command
```
az extension add --name machinelearningservices
```

### Included Features ###
#### machinelearningservices workspace ####
##### Create #####
```
az machinelearningservices workspace create \
--identity type="SystemAssigned,UserAssigned" userAssignedIdentities={"/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/Microsoft.ManagedIdentity/userAssignedIdentities/testuai":{}} \
--location "eastus2euap" --description "test description" \
--application-insights "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/microsoft.insights/components/testinsights" \
--container-registry "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/Microsoft.ContainerRegistry/registries/testRegistry" \
--identity user-assigned-identity="/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/Microsoft.ManagedIdentity/userAssignedIdentities/testuai" \
--key-vault-properties identity-client-id="" key-identifier="https://testkv.vault.azure.net/keys/testkey/aabbccddee112233445566778899aabb" key-vault-arm-id="/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/Microsoft.KeyVault/vaults/testkv" \
--status "Enabled" --friendly-name "HelloName" --hbi-workspace false \
--key-vault "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/Microsoft.KeyVault/vaults/testkv" \
--shared-private-link-resources name="testdbresource" private-link-resource-id="/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/Microsoft.DocumentDB/databaseAccounts/testdbresource/privateLinkResources/Sql" group-id="Sql" request-message="Please approve" status="Approved" \
--storage-account "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/accountcrud-1234/providers/Microsoft.Storage/storageAccounts/testStorageAccount" \
--resource-group "workspace-1234" --name "testworkspace"

az machinelearningservices workspace wait --created --resource-group "{rg}" --name "{myWorkspace}"
```
##### Show #####
```
az machinelearningservices workspace show --resource-group "workspace-1234" --name "testworkspace"
```
##### List #####
```
az machinelearningservices workspace list --resource-group "workspace-1234"
```
##### Update #####
```
az machinelearningservices workspace update --description "new description" --friendly-name "New friendly name" \
--public-network-access "Disabled" --resource-group "workspace-1234" --name "testworkspace"
```
##### Diagnose #####
```
az machinelearningservices workspace diagnose --application-insights "{}" --container-registry "{}" \
--dns-resolution "{}" --key-vault "{}" --nsg "{}" --others "{}" --resource-lock "{}" --storage-account "{}" \
--udr "{}" --resource-group "workspace-1234" --name "testworkspace"
```
##### List-key #####
```
az machinelearningservices workspace list-key --resource-group "testrg123" --name "workspaces123"
```
##### List-notebook-access-token #####
```
az machinelearningservices workspace list-notebook-access-token --resource-group "workspace-1234" \
--name "testworkspace"
```
##### List-notebook-key #####
```
az machinelearningservices workspace list-notebook-key --resource-group "testrg123" --name "workspaces123"
```
##### List-outbound-network-dependency-endpoint #####
```
az machinelearningservices workspace list-outbound-network-dependency-endpoint --resource-group "workspace-1234" \
--name "testworkspace"
```
##### List-storage-account-key #####
```
az machinelearningservices workspace list-storage-account-key --resource-group "testrg123" --name "workspaces123"
```
##### Prepare-notebook #####
```
az machinelearningservices workspace prepare-notebook --resource-group "testrg123" --name "workspaces123"
```
##### Resync-key #####
```
az machinelearningservices workspace resync-key --resource-group "testrg123" --name "workspaces123"
```
##### Delete #####
```
az machinelearningservices workspace delete --resource-group "workspace-1234" --name "testworkspace"
```
#### machinelearningservices usage ####
##### List #####
```
az machinelearningservices usage list --location "eastus"
```
#### machinelearningservices virtual-machine-size ####
##### List #####
```
az machinelearningservices virtual-machine-size list --location "eastus"
```
#### machinelearningservices quota ####
##### List #####
```
az machinelearningservices quota list --location "eastus"
```
##### Update #####
```
az machinelearningservices quota update --location "eastus" \
--value type="Microsoft.MachineLearningServices/workspaces/quotas" id="/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg/providers/Microsoft.MachineLearningServices/workspaces/demo_workspace1/quotas/Standard_DSv2_Family_Cluster_Dedicated_vCPUs" limit=100 unit="Count" \
--value type="Microsoft.MachineLearningServices/workspaces/quotas" id="/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg/providers/Microsoft.MachineLearningServices/workspaces/demo_workspace2/quotas/Standard_DSv2_Family_Cluster_Dedicated_vCPUs" limit=200 unit="Count"
```
#### machinelearningservices compute ####
##### Create #####
```
az machinelearningservices compute create --name "compute123" --location "eastus" \
--properties "{\\"description\\":\\"some compute\\",\\"computeType\\":\\"Kubernetes\\",\\"properties\\":{\\"defaultInstanceType\\":\\"defaultInstanceType\\",\\"instanceTypes\\":{\\"defaultInstanceType\\":{\\"nodeSelector\\":null,\\"resources\\":{\\"limits\\":{\\"cpu\\":\\"1\\",\\"memory\\":\\"4Gi\\",\\"nvidia.com/gpu\\":null},\\"requests\\":{\\"cpu\\":\\"1\\",\\"memory\\":\\"4Gi\\",\\"nvidia.com/gpu\\":null}}}},\\"namespace\\":\\"default\\"},\\"resourceId\\":\\"/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourcegroups/testrg123/providers/Microsoft.ContainerService/managedClusters/compute123-56826-c9b00420020b2\\"}" \
--resource-group "testrg123" --workspace-name "workspaces123"
```
##### Create #####
```
az machinelearningservices compute create --name "compute123" --location "eastus" \
--properties "{\\"computeType\\":\\"AmlCompute\\",\\"properties\\":{\\"enableNodePublicIp\\":true,\\"isolatedNetwork\\":false,\\"osType\\":\\"Windows\\",\\"remoteLoginPortPublicAccess\\":\\"NotSpecified\\",\\"scaleSettings\\":{\\"maxNodeCount\\":1,\\"minNodeCount\\":0,\\"nodeIdleTimeBeforeScaleDown\\":\\"PT5M\\"},\\"virtualMachineImage\\":{\\"id\\":\\"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Compute/galleries/myImageGallery/images/myImageDefinition/versions/0.0.1\\"},\\"vmPriority\\":\\"Dedicated\\",\\"vmSize\\":\\"STANDARD_NC6\\"}}" \
--resource-group "testrg123" --workspace-name "workspaces123"
```
##### Create #####
```
az machinelearningservices compute create --name "compute123" --location "eastus" \
--properties "{\\"computeType\\":\\"DataFactory\\"}" --resource-group "testrg123" --workspace-name "workspaces123"
```
##### Create #####
```
az machinelearningservices compute create --name "compute123" --location "eastus" \
--properties "{\\"computeType\\":\\"AKS\\"}" --resource-group "testrg123" --workspace-name "workspaces123"
```
##### Create #####
```
az machinelearningservices compute create --name "compute123" --location "eastus" \
--properties "{\\"computeType\\":\\"ComputeInstance\\",\\"properties\\":{\\"applicationSharingPolicy\\":\\"Personal\\",\\"computeInstanceAuthorizationType\\":\\"personal\\",\\"personalComputeInstanceSettings\\":{\\"assignedUser\\":{\\"objectId\\":\\"00000000-0000-0000-0000-000000000000\\",\\"tenantId\\":\\"00000000-0000-0000-0000-000000000000\\"}},\\"sshSettings\\":{\\"sshPublicAccess\\":\\"Disabled\\"},\\"subnet\\":\\"test-subnet-resource-id\\",\\"vmSize\\":\\"STANDARD_NC6\\"}}" \
--resource-group "testrg123" --workspace-name "workspaces123"
```
##### Create #####
```
az machinelearningservices compute create --name "compute123" --location "eastus" \
--properties "{\\"computeType\\":\\"ComputeInstance\\",\\"properties\\":{\\"vmSize\\":\\"STANDARD_NC6\\"}}" \
--resource-group "testrg123" --workspace-name "workspaces123"
```
##### Show #####
```
az machinelearningservices compute show --name "compute123" --resource-group "testrg123" \
--workspace-name "workspaces123"
```
##### Show #####
```
az machinelearningservices compute show --name "compute123" --resource-group "testrg123" \
--workspace-name "workspaces123"
```
##### Show #####
```
az machinelearningservices compute show --name "compute123" --resource-group "testrg123" \
--workspace-name "workspaces123"
```
##### Show #####
```
az machinelearningservices compute show --name "compute123" --resource-group "testrg123" \
--workspace-name "workspaces123"
```
##### List #####
```
az machinelearningservices compute list --resource-group "testrg123" --workspace-name "workspaces123"
```
##### Update #####
```
az machinelearningservices compute update --name "compute123" \
--scale-settings max-node-count=4 min-node-count=4 node-idle-time-before-scale-down="PT5M" \
--resource-group "testrg123" --workspace-name "workspaces123"
```
##### List-key #####
```
az machinelearningservices compute list-key --name "compute123" --resource-group "testrg123" \
--workspace-name "workspaces123"
```
##### List-node #####
```
az machinelearningservices compute list-node --name "compute123" --resource-group "testrg123" \
--workspace-name "workspaces123"
```
##### Restart #####
```
az machinelearningservices compute restart --name "compute123" --resource-group "testrg123" \
--workspace-name "workspaces123"
```
##### Start #####
```
az machinelearningservices compute start --name "compute123" --resource-group "testrg123" \
--workspace-name "workspaces123"
```
##### Stop #####
```
az machinelearningservices compute stop --name "compute123" --resource-group "testrg123" \
--workspace-name "workspaces123"
```
##### Delete #####
```
az machinelearningservices compute delete --name "compute123" --resource-group "testrg123" \
--underlying-resource-action "Delete" --workspace-name "workspaces123"
```
#### machinelearningservices private-endpoint-connection ####
##### Create #####
```
az machinelearningservices private-endpoint-connection create --name "{privateEndpointConnectionName}" \
--private-link-service-connection-state description="Auto-Approved" status="Approved" --resource-group "rg-1234" \
--workspace-name "testworkspace"
```
##### Show #####
```
az machinelearningservices private-endpoint-connection show --name "{privateEndpointConnectionName}" \
--resource-group "rg-1234" --workspace-name "testworkspace"
```
##### List #####
```
az machinelearningservices private-endpoint-connection list --resource-group "rg-1234" --workspace-name "testworkspace"
```
##### Delete #####
```
az machinelearningservices private-endpoint-connection delete --name "{privateEndpointConnectionName}" \
--resource-group "rg-1234" --workspace-name "testworkspace"
```
#### machinelearningservices private-link-resource ####
##### List #####
```
az machinelearningservices private-link-resource list --resource-group "rg-1234" --workspace-name "testworkspace"
```
#### machinelearningservices workspace-connection ####
##### Create #####
```
az machinelearningservices workspace-connection create --connection-name "connection-1" --auth-type "PAT" \
--category "ACR" --target "www.facebook.com" --value "secrets" --resource-group "resourceGroup-1" \
--workspace-name "workspace-1"
```
##### Show #####
```
az machinelearningservices workspace-connection show --connection-name "connection-1" \
--resource-group "resourceGroup-1" --workspace-name "workspace-1"
```
##### List #####
```
az machinelearningservices workspace-connection list --category "ACR" --resource-group "resourceGroup-1" \
--target "www.facebook.com" --workspace-name "workspace-1"
```
##### Delete #####
```
az machinelearningservices workspace-connection delete --connection-name "connection-1" \
--resource-group "resourceGroup-1" --workspace-name "workspace-1"
```
#### machinelearningservices workspace-feature ####
##### List #####
```
az machinelearningservices workspace-feature list --resource-group "myResourceGroup" --workspace-name "testworkspace"
```
#### machinelearningservices workspace-sku ####
##### List #####
```
az machinelearningservices workspace-sku list
```
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from azure.cli.core import AzCommandsLoader
from azext_machinelearningservices.generated._help import helps # pylint: disable=unused-import
try:
from azext_machinelearningservices.manual._help import helps # pylint: disable=reimported
except ImportError:
pass


class AzureMachineLearningWorkspacesCommandsLoader(AzCommandsLoader):

def __init__(self, cli_ctx=None):
from azure.cli.core.commands import CliCommandType
from azext_machinelearningservices.generated._client_factory import cf_machinelearningservices_cl
machinelearningservices_custom = CliCommandType(
operations_tmpl='azext_machinelearningservices.custom#{}',
client_factory=cf_machinelearningservices_cl)
parent = super(AzureMachineLearningWorkspacesCommandsLoader, self)
parent.__init__(cli_ctx=cli_ctx, custom_command_type=machinelearningservices_custom)

def load_command_table(self, args):
from azext_machinelearningservices.generated.commands import load_command_table
load_command_table(self, args)
try:
from azext_machinelearningservices.manual.commands import load_command_table as load_command_table_manual
load_command_table_manual(self, args)
except ImportError:
pass
return self.command_table

def load_arguments(self, command):
from azext_machinelearningservices.generated._params import load_arguments
load_arguments(self, command)
try:
from azext_machinelearningservices.manual._params import load_arguments as load_arguments_manual
load_arguments_manual(self, command)
except ImportError:
pass


COMMAND_LOADER_CLS = AzureMachineLearningWorkspacesCommandsLoader
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------
# pylint: disable=wildcard-import
# pylint: disable=unused-wildcard-import

from .generated.action import * # noqa: F403
try:
from .manual.action import * # noqa: F403
except ImportError:
pass
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"azext.isExperimental": true,
"azext.minCliCoreVersion": "2.15.0"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------
# pylint: disable=wildcard-import
# pylint: disable=unused-wildcard-import

from .generated.custom import * # noqa: F403
try:
from .manual.custom import * # noqa: F403
except ImportError:
pass
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

__path__ = __import__('pkgutil').extend_path(__path__, __name__)
Loading