Skip to main content

kms_configs

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

Overview​

Namekms_configs
TypeResource
Idgoogle.netapp.kms_configs

Fields​

The following fields are returned by SELECT queries:

NameDatatypeDescription
namestringIdentifier. Name of the KmsConfig. Format: projects/{project}/locations/{location}/kmsConfigs/{kms_config}
createTimestring (google-datetime)Output only. Create time of the KmsConfig.
cryptoKeyNamestringRequired. Customer-managed crypto key resource full name. Format: projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}
descriptionstringDescription of the KmsConfig.
instructionsstringOutput only. Instructions to provide the access to the customer provided encryption key.
labelsobjectLabels as key value pairs
serviceAccountstringOutput only. The Service account which will have access to the customer provided encryption key.
statestringOutput only. State of the KmsConfig. (STATE_UNSPECIFIED, READY, CREATING, DELETING, UPDATING, IN_USE, ERROR, KEY_CHECK_PENDING, KEY_NOT_REACHABLE, DISABLING, DISABLED, MIGRATING)
stateDetailsstringOutput only. State details of the KmsConfig.

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectprojectsId, locationsId, kmsConfigsIdReturns the description of the specified KMS config by kms_config_id.
listselectprojectsId, locationsIdfilter, orderBy, pageSize, pageTokenReturns descriptions of all KMS configs owned by the caller.
createinsertprojectsId, locationsIdkmsConfigIdCreates a new KMS config.
patchupdateprojectsId, locationsId, kmsConfigsIdupdateMaskUpdates the Kms config properties with the full spec
deletedeleteprojectsId, locationsId, kmsConfigsIdWarning! This operation will permanently delete the Kms config.
encryptexecprojectsId, locationsId, kmsConfigsIdEncrypt the existing volumes without CMEK encryption with the desired the KMS config for the whole region.
verifyexecprojectsId, locationsId, kmsConfigsIdVerifies KMS config reachability.

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
kmsConfigsIdstring
locationsIdstring
projectsIdstring
filterstring
kmsConfigIdstring
orderBystring
pageSizeinteger (int32)
pageTokenstring
updateMaskstring (google-fieldmask)

SELECT examples​

Returns the description of the specified KMS config by kms_config_id.

SELECT
name,
createTime,
cryptoKeyName,
description,
instructions,
labels,
serviceAccount,
state,
stateDetails
FROM google.netapp.kms_configs
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND kmsConfigsId = '{{ kmsConfigsId }}' -- required
;

INSERT examples​

Creates a new KMS config.

INSERT INTO google.netapp.kms_configs (
data__cryptoKeyName,
data__description,
data__labels,
data__name,
projectsId,
locationsId,
kmsConfigId
)
SELECT
'{{ cryptoKeyName }}',
'{{ description }}',
'{{ labels }}',
'{{ name }}',
'{{ projectsId }}',
'{{ locationsId }}',
'{{ kmsConfigId }}'
RETURNING
name,
done,
error,
metadata,
response
;

UPDATE examples​

Updates the Kms config properties with the full spec

UPDATE google.netapp.kms_configs
SET
data__cryptoKeyName = '{{ cryptoKeyName }}',
data__description = '{{ description }}',
data__labels = '{{ labels }}',
data__name = '{{ name }}'
WHERE
projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND kmsConfigsId = '{{ kmsConfigsId }}' --required
AND updateMask = '{{ updateMask}}'
RETURNING
name,
done,
error,
metadata,
response;

DELETE examples​

Warning! This operation will permanently delete the Kms config.

DELETE FROM google.netapp.kms_configs
WHERE projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND kmsConfigsId = '{{ kmsConfigsId }}' --required
;

Lifecycle Methods​

Encrypt the existing volumes without CMEK encryption with the desired the KMS config for the whole region.

EXEC google.netapp.kms_configs.encrypt
@projectsId='{{ projectsId }}' --required,
@locationsId='{{ locationsId }}' --required,
@kmsConfigsId='{{ kmsConfigsId }}' --required
;