Skip to main content

virtual_machine_templates

Creates, updates, deletes, gets or lists a virtual_machine_templates resource.

Overview

Namevirtual_machine_templates
TypeResource
Idazure_isv.connectedvmware.virtual_machine_templates

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringGets or sets the Id.
namestringGets or sets the name.
customResourceNamestringGets the name of the corresponding resource in Kubernetes.
disksarrayGets or sets the disks the template.
extendedLocationobjectGets or sets the extended location.
firmwareTypestringFirmware type. Known values are: "bios" and "efi".
folderPathstringGets or sets the folder path of the template.
inventoryItemIdstringGets or sets the inventory Item ID for the virtual machine template.
kindstringMetadata used by portal/tooling/etc to render different UX experiences for resources of the same type; e.g. ApiApps are a kind of Microsoft.Web/sites type. If supported, the resource provider must validate and persist this value.
locationstringGets or sets the location. Required.
memorySizeMBintegerGets or sets memory size in MBs for the template.
moNamestringGets or sets the vCenter Managed Object name for the virtual machine template.
moRefIdstringGets or sets the vCenter MoRef (Managed Object Reference) ID for the virtual machine template.
networkInterfacesarrayGets or sets the network interfaces of the template.
numCPUsintegerGets or sets the number of vCPUs for the template.
numCoresPerSocketintegerGets or sets the number of cores per socket for the template. Defaults to 1 if unspecified.
osNamestringGets or sets os name.
osTypestringGets or sets the type of the os. Known values are: "Windows", "Linux", and "Other".
provisioningStatestringGets the provisioning state. Known values are: "Succeeded", "Failed", "Canceled", "Provisioning", "Updating", "Deleting", "Accepted", and "Created".
statusesarrayThe resource status information.
systemDataobjectThe system data.
tagsobjectGets or sets the Resource tags.
toolsVersionstringGets or sets the current version of VMware Tools.
toolsVersionStatusstringGets or sets the current version status of VMware Tools installed in the guest operating system.
typestringGets or sets the type of the resource.
uuidstringGets or sets a unique identifier for this resource.
vCenterIdstringGets or sets the ARM Id of the vCenter resource in which this template resides.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectresource_group_name, virtual_machine_template_name, subscription_idGets a virtual machine template. Implements virtual machine template GET method.
list_by_resource_groupselectresource_group_name, subscription_idImplements GET virtualMachineTemplates in a resource group. List of virtualMachineTemplates in a resource group.
listselectsubscription_idImplements GET virtualMachineTemplates in a subscription. List of virtualMachineTemplates in a subscription.
createinsertresource_group_name, virtual_machine_template_name, subscription_id, locationImplements virtual machine template PUT method. Create Or Update virtual machine template.
updateupdateresource_group_name, virtual_machine_template_name, subscription_idUpdates a virtual machine template. API to update certain properties of the virtual machine template resource.
deletedeleteresource_group_name, virtual_machine_template_name, subscription_idforceDeletes an virtual machine template. Implements virtual machine template DELETE method.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
resource_group_namestringThe Resource Group Name. Required.
subscription_idstring
virtual_machine_template_namestringName of the virtual machine template resource. Required.
forcebooleanWhether force delete was specified. Default value is None.

SELECT examples

Gets a virtual machine template. Implements virtual machine template GET method.

SELECT
id,
name,
customResourceName,
disks,
extendedLocation,
firmwareType,
folderPath,
inventoryItemId,
kind,
location,
memorySizeMB,
moName,
moRefId,
networkInterfaces,
numCPUs,
numCoresPerSocket,
osName,
osType,
provisioningState,
statuses,
systemData,
tags,
toolsVersion,
toolsVersionStatus,
type,
uuid,
vCenterId
FROM azure_isv.connectedvmware.virtual_machine_templates
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND virtual_machine_template_name = '{{ virtual_machine_template_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;

INSERT examples

Implements virtual machine template PUT method. Create Or Update virtual machine template.

INSERT INTO azure_isv.connectedvmware.virtual_machine_templates (
location,
extendedLocation,
tags,
kind,
properties,
resource_group_name,
virtual_machine_template_name,
subscription_id
)
SELECT
'{{ location }}' /* required */,
'{{ extendedLocation }}',
'{{ tags }}',
'{{ kind }}',
'{{ properties }}',
'{{ resource_group_name }}',
'{{ virtual_machine_template_name }}',
'{{ subscription_id }}'
RETURNING
id,
name,
extendedLocation,
kind,
location,
properties,
systemData,
tags,
type
;

UPDATE examples

Updates a virtual machine template. API to update certain properties of the virtual machine template resource.

UPDATE azure_isv.connectedvmware.virtual_machine_templates
SET
tags = '{{ tags }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND virtual_machine_template_name = '{{ virtual_machine_template_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
RETURNING
id,
name,
extendedLocation,
kind,
location,
properties,
systemData,
tags,
type;

DELETE examples

Deletes an virtual machine template. Implements virtual machine template DELETE method.

DELETE FROM azure_isv.connectedvmware.virtual_machine_templates
WHERE resource_group_name = '{{ resource_group_name }}' --required
AND virtual_machine_template_name = '{{ virtual_machine_template_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
AND force = '{{ force }}'
;