Skip to main content

machines

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

Overview

Namemachines
TypeResource
Idazure.container_service.machines

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringFully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}.
namestringThe name of the resource.
billingobjectThe properties having to do with machine billing.
eTagstringUnique read-only string used to implement optimistic concurrency. The eTag value will change when the resource is updated. Specify an if-match or if-none-match header with the eTag value for a subsequent request to enable optimistic concurrency per the normal eTag convention.
evictionPolicystringThe eviction policy for machine. This cannot be specified unless the priority is 'Spot'. If not specified, the default is 'Delete'. Known values are: "Delete" and "Deallocate". (Delete, Deallocate)
hardwareobjectThe hardware and GPU settings of the machine.
kubernetesobjectThe Kubernetes configurations used by the machine.
localDNSProfileobjectConfigures the per-node local DNS, with VnetDNS and KubeDNS overrides. LocalDNS helps improve performance and reliability of DNS resolution in an AKS cluster. For more details see aka.ms/aks/localdns.
modestringMachine only allows 'System' and 'User' mode. Known values are: "System", "User", "Gateway", "ManagedSystem", and "Machines". (System, User, Gateway, ManagedSystem, Machines)
networkobjectnetwork properties of the machine.
nodeImageVersionstringThe version of node image.
operatingSystemobjectThe operating system and disk used by the machine.
prioritystringThe priority for the machine. If not specified, the default is 'Regular'. Known values are: "Spot" and "Regular". (Spot, Regular)
provisioningStatestringThe current deployment or provisioning state.
resourceIdstringAzure resource id of the machine. It can be used to GET underlying VM Instance.
securityobjectThe security settings of the machine.
statusobjectContains read-only information about the machine.
systemDataobjectAzure Resource Manager metadata containing createdBy and modifiedBy information.
tagsobjectThe tags to be persisted on the machine.
typestringThe type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts".
zonesarrayThe Availability zone in which machine is located.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectresource_group_name, resource_name, agent_pool_name, machine_name, subscription_idGet a specific machine in the specified agent pool.
listselectresource_group_name, resource_name, agent_pool_name, subscription_idGets a list of machines in the specified agent pool.
create_or_updateinsertresource_group_name, resource_name, agent_pool_name, machine_name, subscription_idCreates or updates a machine in the specified agent pool.
create_or_updatereplaceresource_group_name, resource_name, agent_pool_name, machine_name, subscription_idCreates or updates a machine in the specified agent pool.

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
agent_pool_namestringThe name of the agent pool. Required.
machine_namestringHost name of the machine. Required.
resource_group_namestringThe name of the resource group. The name is case insensitive. Required.
resource_namestringThe name of the managed cluster resource. Required.
subscription_idstring

SELECT examples

Get a specific machine in the specified agent pool.

SELECT
id,
name,
billing,
eTag,
evictionPolicy,
hardware,
kubernetes,
localDNSProfile,
mode,
network,
nodeImageVersion,
operatingSystem,
priority,
provisioningState,
resourceId,
security,
status,
systemData,
tags,
type,
zones
FROM azure.container_service.machines
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND resource_name = '{{ resource_name }}' -- required
AND agent_pool_name = '{{ agent_pool_name }}' -- required
AND machine_name = '{{ machine_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;

INSERT examples

Creates or updates a machine in the specified agent pool.

INSERT INTO azure.container_service.machines (
properties,
zones,
resource_group_name,
resource_name,
agent_pool_name,
machine_name,
subscription_id
)
SELECT
'{{ properties }}',
'{{ zones }}',
'{{ resource_group_name }}',
'{{ resource_name }}',
'{{ agent_pool_name }}',
'{{ machine_name }}',
'{{ subscription_id }}'
RETURNING
id,
name,
properties,
systemData,
type,
zones
;

REPLACE examples

Creates or updates a machine in the specified agent pool.

REPLACE azure.container_service.machines
SET
properties = '{{ properties }}',
zones = '{{ zones }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND resource_name = '{{ resource_name }}' --required
AND agent_pool_name = '{{ agent_pool_name }}' --required
AND machine_name = '{{ machine_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
RETURNING
id,
name,
properties,
systemData,
type,
zones;