az lab custom-image

Manage custom images of a DevTest Lab.

Commands

az lab custom-image create Create a custom image in a DevTest Lab.
az lab custom-image delete Delete custom image.
az lab custom-image list List custom images in a given lab.
az lab custom-image show Get custom image.

az lab custom-image create

Create a custom image in a DevTest Lab.

az lab custom-image create --lab-name
--name
--os-state
--os-type
--resource-group
--source-vm-id
[--author]
[--description]

Examples

Create a custom image in the lab from a running Windows virtual machine without applying sysprep.

az lab custom-image create --lab-name MyLab -g MyRG --name MyVM     --os-type Windows --os-state NonSysprepped     --source-vm-id "/subscriptions/{SubID}/resourcegroups/{MyRG}/microsoft.devtestlab/labs/{MyLab}/virtualmachines/{MyVM}"

Required Parameters

--lab-name
Name of the Lab.
--name -n
Name of the image.
--os-state
The current state of the virtual machine.
--os-type
Type of the OS on which the custom image is based. Allowed values are: Windows, Linux.
--resource-group -g
Name of lab's resource group. You can configure the default group using 'az configure --defaults group='.
--source-vm-id
The resource ID of a virtual machine in the provided lab.

Optional Parameters

--author
The author of the custom image.
--description
A detailed description for the custom image.

az lab custom-image delete

Delete custom image.

az lab custom-image delete --lab-name
--name
--resource-group

Required Parameters

--lab-name
The name of the lab.
--name
The name of the custom image.
--resource-group -g
Name of resource group. You can configure the default group using `az configure --defaults group=<name>`.

az lab custom-image list

List custom images in a given lab.

az lab custom-image list --lab-name
--resource-group
[--expand]
[--filter]
[--orderby]
[--top]

Required Parameters

--lab-name
The name of the lab.
--resource-group -g
Name of resource group. You can configure the default group using `az configure --defaults group=<name>`.

Optional Parameters

--expand
Specify the $expand query. Example: 'properties($select=vm)'.
--filter
The filter to apply to the operation.
--orderby
The ordering expression for the results, using OData notation.
--top
The maximum number of resources to return from the operation.

az lab custom-image show

Get custom image.

az lab custom-image show --lab-name
--name
--resource-group
[--expand]

Required Parameters

--lab-name
The name of the lab.
--name
The name of the custom image.
--resource-group -g
Name of resource group. You can configure the default group using `az configure --defaults group=<name>`.

Optional Parameters

--expand
Specify the $expand query. Example: 'properties($select=vm)'.