Skip to main content

hybrid_runbook_workers

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

Overview

Namehybrid_runbook_workers
TypeResource
Idazure.automation.hybrid_runbook_workers

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.
ipstringGets or sets the assigned machine IP address.
lastSeenDateTimestring (date-time)Last Heartbeat from the Worker.
locationstringThe geo-location where the resource lives. Required.
registeredDateTimestring (date-time)Gets or sets the registration time of the worker machine.
systemDataobjectAzure Resource Manager metadata containing createdBy and modifiedBy information.
tagsobjectResource tags.
typestringThe type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts".
vmResourceIdstringAzure Resource Manager Id for a virtual machine.
workerNamestringName of the HybridWorker.
workerTypestringType of the HybridWorker. Known values are: "HybridV1" and "HybridV2". (HybridV1, HybridV2)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectresource_group_name, automation_account_name, hybrid_runbook_worker_group_name, hybrid_runbook_worker_id, subscription_idRetrieve a hybrid runbook worker.
list_by_hybrid_runbook_worker_groupselectresource_group_name, automation_account_name, hybrid_runbook_worker_group_name, subscription_id$filterRetrieve a list of hybrid runbook workers.
createinsertresource_group_name, automation_account_name, hybrid_runbook_worker_group_name, hybrid_runbook_worker_id, subscription_idCreate a hybrid runbook worker.
deletedeleteresource_group_name, automation_account_name, hybrid_runbook_worker_group_name, hybrid_runbook_worker_id, subscription_idDelete a hybrid runbook worker.
patchexecresource_group_name, automation_account_name, hybrid_runbook_worker_group_name, hybrid_runbook_worker_id, subscription_idUpdate a hybrid runbook worker.
moveexecresource_group_name, automation_account_name, hybrid_runbook_worker_group_name, hybrid_runbook_worker_id, subscription_idMove a hybrid worker to a different group.

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
automation_account_namestringThe name of the automation account. Required.
hybrid_runbook_worker_group_namestringThe hybrid runbook worker group name. Required.
hybrid_runbook_worker_idstringThe hybrid runbook worker id. Required.
resource_group_namestringThe name of the resource group. The name is case insensitive. Required.
subscription_idstring
$filterstringThe filter to apply on the operation. Default value is None.

SELECT examples

Retrieve a hybrid runbook worker.

SELECT
id,
name,
ip,
lastSeenDateTime,
location,
registeredDateTime,
systemData,
tags,
type,
vmResourceId,
workerName,
workerType
FROM azure.automation.hybrid_runbook_workers
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND automation_account_name = '{{ automation_account_name }}' -- required
AND hybrid_runbook_worker_group_name = '{{ hybrid_runbook_worker_group_name }}' -- required
AND hybrid_runbook_worker_id = '{{ hybrid_runbook_worker_id }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;

INSERT examples

Create a hybrid runbook worker.

INSERT INTO azure.automation.hybrid_runbook_workers (
properties,
resource_group_name,
automation_account_name,
hybrid_runbook_worker_group_name,
hybrid_runbook_worker_id,
subscription_id
)
SELECT
'{{ properties }}',
'{{ resource_group_name }}',
'{{ automation_account_name }}',
'{{ hybrid_runbook_worker_group_name }}',
'{{ hybrid_runbook_worker_id }}',
'{{ subscription_id }}'
RETURNING
id,
name,
location,
properties,
systemData,
tags,
type
;

DELETE examples

Delete a hybrid runbook worker.

DELETE FROM azure.automation.hybrid_runbook_workers
WHERE resource_group_name = '{{ resource_group_name }}' --required
AND automation_account_name = '{{ automation_account_name }}' --required
AND hybrid_runbook_worker_group_name = '{{ hybrid_runbook_worker_group_name }}' --required
AND hybrid_runbook_worker_id = '{{ hybrid_runbook_worker_id }}' --required
AND subscription_id = '{{ subscription_id }}' --required
;

Lifecycle Methods

Update a hybrid runbook worker.

EXEC azure.automation.hybrid_runbook_workers.patch 
@resource_group_name='{{ resource_group_name }}' --required,
@automation_account_name='{{ automation_account_name }}' --required,
@hybrid_runbook_worker_group_name='{{ hybrid_runbook_worker_group_name }}' --required,
@hybrid_runbook_worker_id='{{ hybrid_runbook_worker_id }}' --required,
@subscription_id='{{ subscription_id }}' --required
@@json=
'{
"properties": "{{ properties }}"
}'
;