Skip to main content

snapshot_copy_configurations

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

Overview

Namesnapshot_copy_configurations
TypeResource
Idaws.redshift_serverless.snapshot_copy_configurations

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
destination_kms_key_idstringThe ID of the KMS key to use to encrypt your snapshots in the destination Amazon Web Services Region.
destination_regionstringThe destination Amazon Web Services Region to copy snapshots to.
namespace_namestringThe name of the namespace to copy snapshots from in the source Amazon Web Services Region. (pattern: <code>^[a-z0-9-]+$</code>)
snapshot_copy_configuration_arnstringThe ARN of the snapshot copy configuration object.
snapshot_copy_configuration_idstringThe ID of the snapshot copy configuration object.
snapshot_retention_periodintegerThe retention period of snapshots that are copied to the destination Amazon Web Services Region.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
list_snapshot_copy_configurationsselectregionReturns a list of snapshot copy configurations.
create_snapshot_copy_configurationinsertregion, destinationRegion, namespaceNameCreates a snapshot copy configuration that lets you copy snapshots to another Amazon Web Services Region.
update_snapshot_copy_configurationupdateregion, snapshotCopyConfigurationIdUpdates a snapshot copy configuration.
delete_snapshot_copy_configurationdeleteregionDeletes a snapshot copy configuration

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
regionstringAWS region (default: us-east-1)

SELECT examples

Returns a list of snapshot copy configurations.

SELECT
destination_kms_key_id,
destination_region,
namespace_name,
snapshot_copy_configuration_arn,
snapshot_copy_configuration_id,
snapshot_retention_period
FROM aws.redshift_serverless.snapshot_copy_configurations
WHERE region = '{{ region }}' -- required
;

INSERT examples

Creates a snapshot copy configuration that lets you copy snapshots to another Amazon Web Services Region.

INSERT INTO aws.redshift_serverless.snapshot_copy_configurations (
destinationKmsKeyId,
destinationRegion,
namespaceName,
snapshotRetentionPeriod,
region
)
SELECT
'{{ destinationKmsKeyId }}',
'{{ destinationRegion }}' /* required */,
'{{ namespaceName }}' /* required */,
{{ snapshotRetentionPeriod }},
'{{ region }}'
RETURNING
snapshot_copy_configuration
;

UPDATE examples

Updates a snapshot copy configuration.

UPDATE aws.redshift_serverless.snapshot_copy_configurations
SET
snapshotCopyConfigurationId = '{{ snapshotCopyConfigurationId }}',
snapshotRetentionPeriod = {{ snapshotRetentionPeriod }}
WHERE
region = '{{ region }}' --required
AND snapshotCopyConfigurationId = '{{ snapshotCopyConfigurationId }}' --required
RETURNING
snapshot_copy_configuration;

DELETE examples

Deletes a snapshot copy configuration

DELETE FROM aws.redshift_serverless.snapshot_copy_configurations
WHERE region = '{{ region }}' --required
;