Skip to main content

virtual_machine_scale_set_vm_run_commands

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

Overview

Namevirtual_machine_scale_set_vm_run_commands
TypeResource
Idazure.compute.virtual_machine_scale_set_vm_run_commands

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringResource Id
namestringResource name
locationstringResource location
propertiesobjectDescribes the properties of a Virtual Machine run command.
tagsobjectResource tags
typestringResource type

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectresourceGroupName, vmScaleSetName, instanceId, runCommandName, subscriptionId$expandThe operation to get the VMSS VM run command.
listselectresourceGroupName, vmScaleSetName, instanceId, subscriptionId$expandThe operation to get all run commands of an instance in Virtual Machine Scaleset.
create_or_updateinsertresourceGroupName, vmScaleSetName, instanceId, runCommandName, subscriptionIdThe operation to create or update the VMSS VM run command.
updateupdateresourceGroupName, vmScaleSetName, instanceId, runCommandName, subscriptionIdThe operation to update the VMSS VM run command.
deletedeleteresourceGroupName, vmScaleSetName, instanceId, runCommandName, subscriptionIdThe operation to delete the VMSS VM run command.

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
instanceIdstringThe instance ID of the virtual machine.
resourceGroupNamestringThe name of the resource group.
runCommandNamestringThe name of the virtual machine run command.
subscriptionIdstringSubscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
vmScaleSetNamestringThe name of the VM scale set.
$expandstringThe expand expression to apply on the operation.

SELECT examples

The operation to get the VMSS VM run command.

SELECT
id,
name,
location,
properties,
tags,
type
FROM azure.compute.virtual_machine_scale_set_vm_run_commands
WHERE resourceGroupName = '{{ resourceGroupName }}' -- required
AND vmScaleSetName = '{{ vmScaleSetName }}' -- required
AND instanceId = '{{ instanceId }}' -- required
AND runCommandName = '{{ runCommandName }}' -- required
AND subscriptionId = '{{ subscriptionId }}' -- required
AND $expand = '{{ $expand }}'
;

INSERT examples

The operation to create or update the VMSS VM run command.

INSERT INTO azure.compute.virtual_machine_scale_set_vm_run_commands (
data__properties,
data__location,
data__tags,
resourceGroupName,
vmScaleSetName,
instanceId,
runCommandName,
subscriptionId
)
SELECT
'{{ properties }}',
'{{ location }}',
'{{ tags }}',
'{{ resourceGroupName }}',
'{{ vmScaleSetName }}',
'{{ instanceId }}',
'{{ runCommandName }}',
'{{ subscriptionId }}'
RETURNING
id,
name,
location,
properties,
tags,
type
;

UPDATE examples

The operation to update the VMSS VM run command.

UPDATE azure.compute.virtual_machine_scale_set_vm_run_commands
SET
data__properties = '{{ properties }}',
data__tags = '{{ tags }}'
WHERE
resourceGroupName = '{{ resourceGroupName }}' --required
AND vmScaleSetName = '{{ vmScaleSetName }}' --required
AND instanceId = '{{ instanceId }}' --required
AND runCommandName = '{{ runCommandName }}' --required
AND subscriptionId = '{{ subscriptionId }}' --required
RETURNING
id,
name,
location,
properties,
tags,
type;

DELETE examples

The operation to delete the VMSS VM run command.

DELETE FROM azure.compute.virtual_machine_scale_set_vm_run_commands
WHERE resourceGroupName = '{{ resourceGroupName }}' --required
AND vmScaleSetName = '{{ vmScaleSetName }}' --required
AND instanceId = '{{ instanceId }}' --required
AND runCommandName = '{{ runCommandName }}' --required
AND subscriptionId = '{{ subscriptionId }}' --required
;