disk_encryption_sets
Creates, updates, deletes, gets or lists a disk_encryption_sets resource.
Overview
| Name | disk_encryption_sets |
| Type | Resource |
| Id | azure.compute.disk_encryption_sets |
Fields
The following fields are returned by SELECT queries:
- get
- list_by_resource_group
- 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. |
activeKey | object | Key Vault Key Url to be used for server side encryption of Managed Disks and Snapshots. |
autoKeyRotationError | object | The error that was encountered during auto-key rotation. If an error is present, then auto-key rotation will not be attempted until the error on this disk encryption set is fixed. |
encryptionType | string | The type of key used to encrypt the data of the disk. Known values are: "EncryptionAtRestWithCustomerKey", "EncryptionAtRestWithPlatformAndCustomerKeys", and "ConfidentialVmEncryptedWithCustomerKey". (EncryptionAtRestWithCustomerKey, EncryptionAtRestWithPlatformAndCustomerKeys, ConfidentialVmEncryptedWithCustomerKey) |
federatedClientId | string | Multi-tenant application client id to access key vault in a different tenant. Setting the value to 'None' will clear the property. |
identity | object | The managed identity for the disk encryption set. It should be given permission on the key vault before it can be used to encrypt disks. |
lastKeyRotationTimestamp | string (date-time) | The time when the active key of this disk encryption set was updated. |
location | string | The geo-location where the resource lives. Required. |
previousKeys | array | A readonly collection of key vault keys previously used by this disk encryption set while a key rotation is in progress. It will be empty if there is no ongoing key rotation. |
provisioningState | string | The disk encryption set provisioning state. |
rotationToLatestKeyVersionEnabled | boolean | Set this flag to true to enable auto-updating of this disk encryption set to the latest key version. |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
tags | object | Resource tags. |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
| 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. |
activeKey | object | Key Vault Key Url to be used for server side encryption of Managed Disks and Snapshots. |
autoKeyRotationError | object | The error that was encountered during auto-key rotation. If an error is present, then auto-key rotation will not be attempted until the error on this disk encryption set is fixed. |
encryptionType | string | The type of key used to encrypt the data of the disk. Known values are: "EncryptionAtRestWithCustomerKey", "EncryptionAtRestWithPlatformAndCustomerKeys", and "ConfidentialVmEncryptedWithCustomerKey". (EncryptionAtRestWithCustomerKey, EncryptionAtRestWithPlatformAndCustomerKeys, ConfidentialVmEncryptedWithCustomerKey) |
federatedClientId | string | Multi-tenant application client id to access key vault in a different tenant. Setting the value to 'None' will clear the property. |
identity | object | The managed identity for the disk encryption set. It should be given permission on the key vault before it can be used to encrypt disks. |
lastKeyRotationTimestamp | string (date-time) | The time when the active key of this disk encryption set was updated. |
location | string | The geo-location where the resource lives. Required. |
previousKeys | array | A readonly collection of key vault keys previously used by this disk encryption set while a key rotation is in progress. It will be empty if there is no ongoing key rotation. |
provisioningState | string | The disk encryption set provisioning state. |
rotationToLatestKeyVersionEnabled | boolean | Set this flag to true to enable auto-updating of this disk encryption set to the latest key version. |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
tags | object | Resource tags. |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
| 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. |
activeKey | object | Key Vault Key Url to be used for server side encryption of Managed Disks and Snapshots. |
autoKeyRotationError | object | The error that was encountered during auto-key rotation. If an error is present, then auto-key rotation will not be attempted until the error on this disk encryption set is fixed. |
encryptionType | string | The type of key used to encrypt the data of the disk. Known values are: "EncryptionAtRestWithCustomerKey", "EncryptionAtRestWithPlatformAndCustomerKeys", and "ConfidentialVmEncryptedWithCustomerKey". (EncryptionAtRestWithCustomerKey, EncryptionAtRestWithPlatformAndCustomerKeys, ConfidentialVmEncryptedWithCustomerKey) |
federatedClientId | string | Multi-tenant application client id to access key vault in a different tenant. Setting the value to 'None' will clear the property. |
identity | object | The managed identity for the disk encryption set. It should be given permission on the key vault before it can be used to encrypt disks. |
lastKeyRotationTimestamp | string (date-time) | The time when the active key of this disk encryption set was updated. |
location | string | The geo-location where the resource lives. Required. |
previousKeys | array | A readonly collection of key vault keys previously used by this disk encryption set while a key rotation is in progress. It will be empty if there is no ongoing key rotation. |
provisioningState | string | The disk encryption set provisioning state. |
rotationToLatestKeyVersionEnabled | boolean | Set this flag to true to enable auto-updating of this disk encryption set to the latest key version. |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
tags | object | Resource tags. |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | resource_group_name, disk_encryption_set_name, subscription_id | Gets information about a disk encryption set. | |
list_by_resource_group | select | resource_group_name, subscription_id | Lists all the disk encryption sets under a resource group. | |
list | select | subscription_id | Lists all the disk encryption sets under a subscription. | |
create_or_update | insert | resource_group_name, disk_encryption_set_name, subscription_id, location | Creates or updates a disk encryption set. | |
update | update | resource_group_name, disk_encryption_set_name, subscription_id | Updates (patches) a disk encryption set. | |
create_or_update | replace | resource_group_name, disk_encryption_set_name, subscription_id, location | Creates or updates a disk encryption set. | |
delete | delete | resource_group_name, disk_encryption_set_name, subscription_id | Deletes a disk encryption set. | |
list_associated_resources | exec | resource_group_name, disk_encryption_set_name, subscription_id | Lists all resources that are encrypted with this disk encryption set. |
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 |
|---|---|---|
disk_encryption_set_name | string | The name of the disk encryption set that is being created. The name can't be changed after the disk encryption set is created. Supported characters for the name are a-z, A-Z, 0-9, _ and -. The maximum name length is 80 characters. Required. |
resource_group_name | string | The name of the resource group. The name is case insensitive. Required. |
subscription_id | string |
SELECT examples
- get
- list_by_resource_group
- list
Gets information about a disk encryption set.
SELECT
id,
name,
activeKey,
autoKeyRotationError,
encryptionType,
federatedClientId,
identity,
lastKeyRotationTimestamp,
location,
previousKeys,
provisioningState,
rotationToLatestKeyVersionEnabled,
systemData,
tags,
type
FROM azure.compute.disk_encryption_sets
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND disk_encryption_set_name = '{{ disk_encryption_set_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
Lists all the disk encryption sets under a resource group.
SELECT
id,
name,
activeKey,
autoKeyRotationError,
encryptionType,
federatedClientId,
identity,
lastKeyRotationTimestamp,
location,
previousKeys,
provisioningState,
rotationToLatestKeyVersionEnabled,
systemData,
tags,
type
FROM azure.compute.disk_encryption_sets
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
Lists all the disk encryption sets under a subscription.
SELECT
id,
name,
activeKey,
autoKeyRotationError,
encryptionType,
federatedClientId,
identity,
lastKeyRotationTimestamp,
location,
previousKeys,
provisioningState,
rotationToLatestKeyVersionEnabled,
systemData,
tags,
type
FROM azure.compute.disk_encryption_sets
WHERE subscription_id = '{{ subscription_id }}' -- required
;
INSERT examples
- create_or_update
- Manifest
Creates or updates a disk encryption set.
INSERT INTO azure.compute.disk_encryption_sets (
tags,
location,
properties,
identity,
resource_group_name,
disk_encryption_set_name,
subscription_id
)
SELECT
'{{ tags }}',
'{{ location }}' /* required */,
'{{ properties }}',
'{{ identity }}',
'{{ resource_group_name }}',
'{{ disk_encryption_set_name }}',
'{{ subscription_id }}'
RETURNING
id,
name,
identity,
location,
properties,
systemData,
tags,
type
;
# Description fields are for documentation purposes
- name: disk_encryption_sets
props:
- name: resource_group_name
value: "{{ resource_group_name }}"
description: Required parameter for the disk_encryption_sets resource.
- name: disk_encryption_set_name
value: "{{ disk_encryption_set_name }}"
description: Required parameter for the disk_encryption_sets resource.
- name: subscription_id
value: "{{ subscription_id }}"
description: Required parameter for the disk_encryption_sets resource.
- name: tags
value: "{{ tags }}"
description: |
Resource tags.
- name: location
value: "{{ location }}"
description: |
The geo-location where the resource lives. Required.
- name: properties
description: |
:vartype properties: ~azure.mgmt.compute.models.EncryptionSetProperties
value:
encryptionType: "{{ encryptionType }}"
activeKey:
sourceVault:
id: "{{ id }}"
keyUrl: "{{ keyUrl }}"
previousKeys:
- sourceVault:
id: "{{ id }}"
keyUrl: "{{ keyUrl }}"
provisioningState: "{{ provisioningState }}"
rotationToLatestKeyVersionEnabled: {{ rotationToLatestKeyVersionEnabled }}
lastKeyRotationTimestamp: "{{ lastKeyRotationTimestamp }}"
autoKeyRotationError:
details:
- code: "{{ code }}"
target: "{{ target }}"
message: "{{ message }}"
innererror:
exceptiontype: "{{ exceptiontype }}"
errordetail: "{{ errordetail }}"
code: "{{ code }}"
target: "{{ target }}"
message: "{{ message }}"
federatedClientId: "{{ federatedClientId }}"
- name: identity
description: |
The managed identity for the disk encryption set. It should be given permission on the key vault before it can be used to encrypt disks.
value:
type: "{{ type }}"
principalId: "{{ principalId }}"
tenantId: "{{ tenantId }}"
userAssignedIdentities: "{{ userAssignedIdentities }}"
UPDATE examples
- update
Updates (patches) a disk encryption set.
UPDATE azure.compute.disk_encryption_sets
SET
properties = '{{ properties }}',
tags = '{{ tags }}',
identity = '{{ identity }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND disk_encryption_set_name = '{{ disk_encryption_set_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
RETURNING
id,
name,
identity,
location,
properties,
systemData,
tags,
type;
REPLACE examples
- create_or_update
Creates or updates a disk encryption set.
REPLACE azure.compute.disk_encryption_sets
SET
tags = '{{ tags }}',
location = '{{ location }}',
properties = '{{ properties }}',
identity = '{{ identity }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND disk_encryption_set_name = '{{ disk_encryption_set_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
AND location = '{{ location }}' --required
RETURNING
id,
name,
identity,
location,
properties,
systemData,
tags,
type;
DELETE examples
- delete
Deletes a disk encryption set.
DELETE FROM azure.compute.disk_encryption_sets
WHERE resource_group_name = '{{ resource_group_name }}' --required
AND disk_encryption_set_name = '{{ disk_encryption_set_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
;
Lifecycle Methods
- list_associated_resources
Lists all resources that are encrypted with this disk encryption set.
EXEC azure.compute.disk_encryption_sets.list_associated_resources
@resource_group_name='{{ resource_group_name }}' --required,
@disk_encryption_set_name='{{ disk_encryption_set_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
;