virtual_machines
Creates, updates, deletes, gets or lists a virtual_machines
resource.
Overview
Name | virtual_machines |
Type | Resource |
Id | azure_isv.vmware_cloud_simple.virtual_machines |
Fields
- vw_virtual_machines
- virtual_machines
Name | Datatype | Description |
---|---|---|
id | text | /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/virtualMachines/{virtualMachineName} |
name | text | {virtualMachineName} |
amount_of_ram | text | field from the properties object |
controllers | text | field from the properties object |
customization | text | field from the properties object |
disks | text | field from the properties object |
dnsname | text | field from the properties object |
expose_to_guest_vm | text | field from the properties object |
folder | text | field from the properties object |
guest_os | text | field from the properties object |
guest_os_type | text | field from the properties object |
location | text | Azure region |
nics | text | field from the properties object |
number_of_cores | text | field from the properties object |
password | text | field from the properties object |
private_cloud_id | text | field from the properties object |
provisioning_state | text | field from the properties object |
public_ip | text | field from the properties object |
resourceGroupName | text | field from the properties object |
resource_pool | text | field from the properties object |
status | text | field from the properties object |
subscriptionId | text | field from the properties object |
tags | text | Tags model |
template_id | text | field from the properties object |
type | text | {resourceProviderNamespace}/{resourceType} |
username | text | field from the properties object |
v_sphere_networks | text | field from the properties object |
virtualMachineName | text | field from the properties object |
vm_id | text | field from the properties object |
vmwaretools | text | field from the properties object |
Name | Datatype | Description |
---|---|---|
id | string | /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/virtualMachines/{virtualMachineName} |
name | string | {virtualMachineName} |
location | string | Azure region |
properties | object | Properties of virtual machine |
tags | object | Tags model |
type | string | {resourceProviderNamespace}/{resourceType} |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
get | SELECT | resourceGroupName, subscriptionId, virtualMachineName | Get virtual machine |
list_by_resource_group | SELECT | resourceGroupName, subscriptionId | Returns list of virtual machine within resource group |
list_by_subscription | SELECT | subscriptionId | Returns list virtual machine within subscription |
create_or_update | INSERT | Referer, resourceGroupName, subscriptionId, virtualMachineName, data__location | Create Or Update Virtual Machine |
delete | DELETE | Referer, resourceGroupName, subscriptionId, virtualMachineName | Delete virtual machine |
update | UPDATE | resourceGroupName, subscriptionId, virtualMachineName | Patch virtual machine properties |
start | EXEC | Referer, resourceGroupName, subscriptionId, virtualMachineName | Power on virtual machine |
stop | EXEC | Referer, resourceGroupName, subscriptionId, virtualMachineName | Power off virtual machine, options: shutdown, poweroff, and suspend |
SELECT
examples
Returns list virtual machine within subscription
- vw_virtual_machines
- virtual_machines
SELECT
id,
name,
amount_of_ram,
controllers,
customization,
disks,
dnsname,
expose_to_guest_vm,
folder,
guest_os,
guest_os_type,
location,
nics,
number_of_cores,
password,
private_cloud_id,
provisioning_state,
public_ip,
resourceGroupName,
resource_pool,
status,
subscriptionId,
tags,
template_id,
type,
username,
v_sphere_networks,
virtualMachineName,
vm_id,
vmwaretools
FROM azure_isv.vmware_cloud_simple.vw_virtual_machines
WHERE subscriptionId = '{{ subscriptionId }}';
SELECT
id,
name,
location,
properties,
tags,
type
FROM azure_isv.vmware_cloud_simple.virtual_machines
WHERE subscriptionId = '{{ subscriptionId }}';
INSERT
example
Use the following StackQL query and manifest file to create a new virtual_machines
resource.
- All Properties
- Manifest
/*+ create */
INSERT INTO azure_isv.vmware_cloud_simple.virtual_machines (
Referer,
resourceGroupName,
subscriptionId,
virtualMachineName,
data__location,
location,
properties,
tags
)
SELECT
'{{ Referer }}',
'{{ resourceGroupName }}',
'{{ subscriptionId }}',
'{{ virtualMachineName }}',
'{{ data__location }}',
'{{ location }}',
'{{ properties }}',
'{{ tags }}'
;
- name: your_resource_model_name
props:
- name: id
value: string
- name: location
value: string
- name: name
value: string
- name: properties
value:
- name: amountOfRam
value: integer
- name: controllers
value:
- - name: id
value: string
- name: name
value: string
- name: subType
value: string
- name: type
value: string
- name: customization
value:
- name: dnsServers
value:
- []
- name: hostName
value: string
- name: password
value: string
- name: policyId
value: string
- name: username
value: string
- name: disks
value:
- - name: controllerId
value: string
- name: independenceMode
value: string
- name: totalSize
value: integer
- name: virtualDiskId
value: string
- name: virtualDiskName
value: string
- name: dnsname
value: string
- name: exposeToGuestVM
value: boolean
- name: folder
value: string
- name: guestOS
value: string
- name: guestOSType
value: string
- name: nics
value:
- - name: customization
value:
- name: allocation
value: string
- name: dnsServers
value:
- []
- name: gateway
value:
- []
- name: ipAddress
value: []
- name: ipAddresses
value:
- string
- name: macAddress
value: string
- name: network
value:
- name: assignable
value: boolean
- name: id
value: string
- name: location
value: string
- name: name
value: string
- name: properties
value:
- name: privateCloudId
value: string
- name: type
value: string
- name: nicType
value: string
- name: powerOnBoot
value: boolean
- name: virtualNicId
value: string
- name: virtualNicName
value: string
- name: numberOfCores
value: integer
- name: password
value: string
- name: privateCloudId
value: string
- name: provisioningState
value: string
- name: publicIP
value: string
- name: resourcePool
value:
- name: id
value: string
- name: location
value: string
- name: name
value: string
- name: privateCloudId
value: string
- name: properties
value:
- name: fullName
value: string
- name: type
value: string
- name: status
value: string
- name: templateId
value: string
- name: username
value: string
- name: vSphereNetworks
value:
- string
- name: vmId
value: string
- name: vmwaretools
value: string
- name: tags
value: []
- name: type
value: string
UPDATE
example
Updates a virtual_machines
resource.
/*+ update */
UPDATE azure_isv.vmware_cloud_simple.virtual_machines
SET
tags = '{{ tags }}'
WHERE
resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}'
AND virtualMachineName = '{{ virtualMachineName }}';
DELETE
example
Deletes the specified virtual_machines
resource.
/*+ delete */
DELETE FROM azure_isv.vmware_cloud_simple.virtual_machines
WHERE Referer = '{{ Referer }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}'
AND virtualMachineName = '{{ virtualMachineName }}';