accounts
Creates, updates, deletes, gets or lists an accounts
resource.
Overview
Name | accounts |
Type | Resource |
Id | azure.batch.accounts |
Fields
The following fields are returned by SELECT
queries:
- get
- list_by_resource_group
- list
The operation was successful. The response contains the Batch account entity.
Name | Datatype | Description |
---|---|---|
id | string | The ID of the resource. |
name | string | The name of the resource. |
identity | object | The identity of the Batch account. |
location | string | The location of the resource. |
properties | object | The properties associated with the account. |
tags | object | The tags of the resource. |
type | string | The type of the resource. |
The operation was successful. The response contains a list of Batch account entities associated with the resource group.
Name | Datatype | Description |
---|---|---|
id | string | The ID of the resource. |
name | string | The name of the resource. |
identity | object | The identity of the Batch account. |
location | string | The location of the resource. |
properties | object | The properties associated with the account. |
tags | object | The tags of the resource. |
type | string | The type of the resource. |
The operation was successful. The response contains a list of Batch account entities associated with the subscription.
Name | Datatype | Description |
---|---|---|
id | string | The ID of the resource. |
name | string | The name of the resource. |
identity | object | The identity of the Batch account. |
location | string | The location of the resource. |
properties | object | The properties associated with the account. |
tags | object | The tags of the resource. |
type | string | The type of the resource. |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
get | select | resourceGroupName , accountName , subscriptionId | Gets information about the specified Batch account. | |
list_by_resource_group | select | resourceGroupName , subscriptionId | Gets information about the Batch accounts associated with the specified resource group. | |
list | select | subscriptionId | Gets information about the Batch accounts associated with the subscription. | |
create | insert | resourceGroupName , accountName , subscriptionId , data__location | Creates a new Batch account with the specified parameters. Existing accounts cannot be updated with this API and should instead be updated with the Update Batch Account API. | |
update | update | resourceGroupName , accountName , subscriptionId | Updates the properties of an existing Batch account. | |
delete | delete | resourceGroupName , accountName , subscriptionId | Deletes the specified Batch account. | |
synchronize_auto_storage_keys | exec | resourceGroupName , accountName , subscriptionId | Synchronizes access keys for the auto-storage account configured for the specified Batch account, only if storage key authentication is being used. | |
regenerate_key | exec | resourceGroupName , accountName , subscriptionId , keyName | This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to authenticate, and must use another allowedAuthenticationModes instead. In this case, regenerating the keys will fail. |
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 |
---|---|---|
accountName | string | The name of the Batch account. |
resourceGroupName | string | The name of the resource group that contains the Batch account. |
subscriptionId | string | The Azure subscription ID. This is a GUID-formatted string (e.g. 00000000-0000-0000-0000-000000000000) |
SELECT
examples
- get
- list_by_resource_group
- list
Gets information about the specified Batch account.
SELECT
id,
name,
identity,
location,
properties,
tags,
type
FROM azure.batch.accounts
WHERE resourceGroupName = '{{ resourceGroupName }}' -- required
AND accountName = '{{ accountName }}' -- required
AND subscriptionId = '{{ subscriptionId }}' -- required
;
Gets information about the Batch accounts associated with the specified resource group.
SELECT
id,
name,
identity,
location,
properties,
tags,
type
FROM azure.batch.accounts
WHERE resourceGroupName = '{{ resourceGroupName }}' -- required
AND subscriptionId = '{{ subscriptionId }}' -- required
;
Gets information about the Batch accounts associated with the subscription.
SELECT
id,
name,
identity,
location,
properties,
tags,
type
FROM azure.batch.accounts
WHERE subscriptionId = '{{ subscriptionId }}' -- required
;
INSERT
examples
- create
- Manifest
Creates a new Batch account with the specified parameters. Existing accounts cannot be updated with this API and should instead be updated with the Update Batch Account API.
INSERT INTO azure.batch.accounts (
data__location,
data__tags,
data__properties,
data__identity,
resourceGroupName,
accountName,
subscriptionId
)
SELECT
'{{ location }}' /* required */,
'{{ tags }}',
'{{ properties }}',
'{{ identity }}',
'{{ resourceGroupName }}',
'{{ accountName }}',
'{{ subscriptionId }}'
RETURNING
id,
name,
identity,
location,
properties,
tags,
type
;
# Description fields are for documentation purposes
- name: accounts
props:
- name: resourceGroupName
value: string
description: Required parameter for the accounts resource.
- name: accountName
value: string
description: Required parameter for the accounts resource.
- name: subscriptionId
value: string
description: Required parameter for the accounts resource.
- name: location
value: string
description: |
The region in which to create the account.
- name: tags
value: object
description: |
The user-specified tags associated with the account.
- name: properties
value: object
description: |
The properties of the Batch account.
- name: identity
value: object
description: |
The identity of the Batch account.
UPDATE
examples
- update
Updates the properties of an existing Batch account.
UPDATE azure.batch.accounts
SET
data__tags = '{{ tags }}',
data__properties = '{{ properties }}',
data__identity = '{{ identity }}'
WHERE
resourceGroupName = '{{ resourceGroupName }}' --required
AND accountName = '{{ accountName }}' --required
AND subscriptionId = '{{ subscriptionId }}' --required
RETURNING
id,
name,
identity,
location,
properties,
tags,
type;
DELETE
examples
- delete
Deletes the specified Batch account.
DELETE FROM azure.batch.accounts
WHERE resourceGroupName = '{{ resourceGroupName }}' --required
AND accountName = '{{ accountName }}' --required
AND subscriptionId = '{{ subscriptionId }}' --required
;
Lifecycle Methods
- synchronize_auto_storage_keys
- regenerate_key
Synchronizes access keys for the auto-storage account configured for the specified Batch account, only if storage key authentication is being used.
EXEC azure.batch.accounts.synchronize_auto_storage_keys
@resourceGroupName='{{ resourceGroupName }}' --required,
@accountName='{{ accountName }}' --required,
@subscriptionId='{{ subscriptionId }}' --required
;
This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to authenticate, and must use another allowedAuthenticationModes instead. In this case, regenerating the keys will fail.
EXEC azure.batch.accounts.regenerate_key
@resourceGroupName='{{ resourceGroupName }}' --required,
@accountName='{{ accountName }}' --required,
@subscriptionId='{{ subscriptionId }}' --required
@@json=
'{
"keyName": "{{ keyName }}"
}'
;