agent_pools
Creates, updates, deletes, gets or lists an agent_pools resource.
Overview
| Name | agent_pools |
| Type | Resource |
| Id | azure.container_registry_tasks.agent_pools |
Fields
The following fields are returned by SELECT queries:
- get
- list
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. |
name | string | The name of the resource. |
count | integer | The count of agent machine. |
location | string | The geo-location where the resource lives. Required. |
os | string | The OS of agent machine. Known values are: "Windows" and "Linux". (Windows, Linux) |
provisioningState | string | The provisioning state of this agent pool. Known values are: "Creating", "Updating", "Deleting", "Succeeded", "Failed", and "Canceled". (Creating, Updating, Deleting, Succeeded, Failed, Canceled) |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
tags | object | Resource tags. |
tier | string | The Tier of agent machine. |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
virtualNetworkSubnetResourceId | string | The Virtual Network Subnet Resource Id of the agent machine. |
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. |
name | string | The name of the resource. |
count | integer | The count of agent machine. |
location | string | The geo-location where the resource lives. Required. |
os | string | The OS of agent machine. Known values are: "Windows" and "Linux". (Windows, Linux) |
provisioningState | string | The provisioning state of this agent pool. Known values are: "Creating", "Updating", "Deleting", "Succeeded", "Failed", and "Canceled". (Creating, Updating, Deleting, Succeeded, Failed, Canceled) |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
tags | object | Resource tags. |
tier | string | The Tier of agent machine. |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
virtualNetworkSubnetResourceId | string | The Virtual Network Subnet Resource Id of the agent machine. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | resource_group_name, registry_name, agent_pool_name, subscription_id | Gets the detailed information for a given agent pool. | |
list | select | resource_group_name, registry_name, subscription_id | Lists all the agent pools for a specified container registry. | |
create | insert | resource_group_name, registry_name, agent_pool_name, subscription_id, location | Creates an agent pool for a container registry with the specified parameters. | |
update | update | resource_group_name, registry_name, agent_pool_name, subscription_id | Updates an agent pool with the specified parameters. | |
delete | delete | resource_group_name, registry_name, agent_pool_name, subscription_id | Deletes a specified agent pool resource. | |
get_queue_status | exec | resource_group_name, registry_name, agent_pool_name, subscription_id | Gets the count of queued runs for a given 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.
| Name | Datatype | Description |
|---|---|---|
agent_pool_name | string | The name of the agent pool. Required. |
registry_name | string | The name of the Registry. Required. |
resource_group_name | string | The name of the resource group. The name is case insensitive. Required. |
subscription_id | string |
SELECT examples
- get
- list
Gets the detailed information for a given agent pool.
SELECT
id,
name,
count,
location,
os,
provisioningState,
systemData,
tags,
tier,
type,
virtualNetworkSubnetResourceId
FROM azure.container_registry_tasks.agent_pools
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND registry_name = '{{ registry_name }}' -- required
AND agent_pool_name = '{{ agent_pool_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
Lists all the agent pools for a specified container registry.
SELECT
id,
name,
count,
location,
os,
provisioningState,
systemData,
tags,
tier,
type,
virtualNetworkSubnetResourceId
FROM azure.container_registry_tasks.agent_pools
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND registry_name = '{{ registry_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
INSERT examples
- create
- Manifest
Creates an agent pool for a container registry with the specified parameters.
INSERT INTO azure.container_registry_tasks.agent_pools (
tags,
location,
properties,
resource_group_name,
registry_name,
agent_pool_name,
subscription_id
)
SELECT
'{{ tags }}',
'{{ location }}' /* required */,
'{{ properties }}',
'{{ resource_group_name }}',
'{{ registry_name }}',
'{{ agent_pool_name }}',
'{{ subscription_id }}'
RETURNING
id,
name,
location,
properties,
systemData,
tags,
type
;
# Description fields are for documentation purposes
- name: agent_pools
props:
- name: resource_group_name
value: "{{ resource_group_name }}"
description: Required parameter for the agent_pools resource.
- name: registry_name
value: "{{ registry_name }}"
description: Required parameter for the agent_pools resource.
- name: agent_pool_name
value: "{{ agent_pool_name }}"
description: Required parameter for the agent_pools resource.
- name: subscription_id
value: "{{ subscription_id }}"
description: Required parameter for the agent_pools resource.
- name: tags
value: "{{ tags }}"
description: |
Resource tags.
- name: location
value: "{{ location }}"
description: |
The geo-location where the resource lives. Required.
- name: properties
description: |
The properties associated with the agent pool.
value:
count: {{ count }}
tier: "{{ tier }}"
os: "{{ os }}"
virtualNetworkSubnetResourceId: "{{ virtualNetworkSubnetResourceId }}"
provisioningState: "{{ provisioningState }}"
UPDATE examples
- update
Updates an agent pool with the specified parameters.
UPDATE azure.container_registry_tasks.agent_pools
SET
properties = '{{ properties }}',
tags = '{{ tags }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND registry_name = '{{ registry_name }}' --required
AND agent_pool_name = '{{ agent_pool_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
RETURNING
id,
name,
location,
properties,
systemData,
tags,
type;
DELETE examples
- delete
Deletes a specified agent pool resource.
DELETE FROM azure.container_registry_tasks.agent_pools
WHERE resource_group_name = '{{ resource_group_name }}' --required
AND registry_name = '{{ registry_name }}' --required
AND agent_pool_name = '{{ agent_pool_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
;
Lifecycle Methods
- get_queue_status
Gets the count of queued runs for a given agent pool.
EXEC azure.container_registry_tasks.agent_pools.get_queue_status
@resource_group_name='{{ resource_group_name }}' --required,
@registry_name='{{ registry_name }}' --required,
@agent_pool_name='{{ agent_pool_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
;