New-AzMLWorkspaceEnvironmentVersion

Creates or updates an EnvironmentVersion.

Syntax

New-AzMLWorkspaceEnvironmentVersion
   -Name <String>
   -ResourceGroupName <String>
   -Version <String>
   -WorkspaceName <String>
   [-SubscriptionId <String>]
   [-AutoRebuild <AutoRebuildSetting>]
   [-BuildContextUri <String>]
   [-BuildDockerfilePath <String>]
   [-CondaFile <String>]
   [-Description <String>]
   [-Image <String>]
   [-IsAnonymou]
   [-IsArchived]
   [-LivenessRoutePath <String>]
   [-LivenessRoutePort <Int32>]
   [-OSType <OperatingSystemType>]
   [-ReadinessRoutePath <String>]
   [-ReadinessRoutePort <Int32>]
   [-ResourceBaseProperty <Hashtable>]
   [-ScoringRoutePath <String>]
   [-ScoringRoutePort <Int32>]
   [-Stage <String>]
   [-Tag <Hashtable>]
   [-DefaultProfile <PSObject>]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]

Description

Creates or updates an EnvironmentVersion.

Examples

Example 1: Creates or updates an EnvironmentVersion.

New-AzMLWorkspaceEnvironmentVersion -ResourceGroupName ml-rg-test -WorkspaceName mlworkspace-test01 -Name commandjobenv -Version 1 -Image "library/python:latest"

Name SystemDataCreatedAt  SystemDataCreatedBy                 SystemDataCreatedByType SystemDataLastModifiedAt SystemDataLastModifiedBy            SystemDataLastModifiedByType ResourceGroupName
---- -------------------  -------------------                 ----------------------- ------------------------ ------------------------            ---------------------------- -----------------
1    5/31/2022 8:28:35 AM UserName (Example)                  User                    5/31/2022 8:28:35 AM     UserName (Example)                  User                         ml-rg-test

Creates or updates an EnvironmentVersion.

Parameters

-AutoRebuild

Defines if image needs to be rebuilt based on base image changes.

Type:AutoRebuildSetting
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-BuildContextUri

[Required] URI of the Docker build context used to build the image. Supports blob URIs on environment creation and may return blob or Git URIs.<seealso href="https://docs.docker.com/engine/reference/commandline/build/#extended-description" />

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-BuildDockerfilePath

Path to the Dockerfile in the build context.<seealso href="https://docs.docker.com/engine/reference/builder/" />

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-CondaFile

Standard configuration file used by Conda that lets you install any kind of package, including Python, R, and C/C++ packages.<see href="https://repo2docker.readthedocs.io/en/latest/config_files.html#environment-yml-install-a-conda-environment" />

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Confirm

Prompts you for confirmation before running the cmdlet.

Type:SwitchParameter
Aliases:cf
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-DefaultProfile

The DefaultProfile parameter is not functional. Use the SubscriptionId parameter when available if executing the cmdlet against a different subscription.

Type:PSObject
Aliases:AzureRMContext, AzureCredential
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Description

The asset description text.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Image

Name of the image that will be used for the environment.<seealso href="https://docs.microsoft.com/en-us/azure/machine-learning/how-to-deploy-custom-docker-image#use-a-custom-base-image" />

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-IsAnonymou

If the name version are system generated (anonymous registration).

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-IsArchived

Is the asset archived

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-LivenessRoutePath

[Required] The path for the route.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-LivenessRoutePort

[Required] The port for the route.

Type:Int32
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Name

Name of EnvironmentVersion. This is case-sensitive.

Type:String
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-OSType

The OS type of the environment.

Type:OperatingSystemType
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-ReadinessRoutePath

[Required] The path for the route.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-ReadinessRoutePort

[Required] The port for the route.

Type:Int32
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-ResourceBaseProperty

The asset property dictionary.

Type:Hashtable
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-ResourceGroupName

The name of the resource group. The name is case insensitive.

Type:String
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-ScoringRoutePath

[Required] The path for the route.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-ScoringRoutePort

[Required] The port for the route.

Type:Int32
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Stage

Stage in the environment lifecycle assigned to this environment

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-SubscriptionId

The ID of the target subscription.

Type:String
Position:Named
Default value:(Get-AzContext).Subscription.Id
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Tag

Tag dictionary. Tags can be added, removed, and updated.

Type:Hashtable
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Version

Version of EnvironmentVersion.

Type:String
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Type:SwitchParameter
Aliases:wi
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-WorkspaceName

Name of Azure Machine Learning workspace.

Type:String
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

Outputs

IEnvironmentVersion