Skip to content
v2.277.0

BackupVaultProps Struct ​

Properties for a BackupVault.

Example ​

ts
const myKey = kms.Key.fromKeyArn(this, 'MyKey', 'aaa');
const myTopic = sns.Topic.fromTopicArn(this, 'MyTopic', 'bbb');

const vault = new backup.BackupVault(this, 'Vault', {
  encryptionKey: myKey, // Custom encryption key
  notificationTopic: myTopic, // Send all vault events to this SNS topic
});
python
my_key = kms.Key.from_key_arn(self, "MyKey", "aaa")
my_topic = sns.Topic.from_topic_arn(self, "MyTopic", "bbb")

vault = backup.BackupVault(self, "Vault",
    encryption_key=my_key,  # Custom encryption key
    notification_topic=my_topic
)
java
IKey myKey = Key.fromKeyArn(this, "MyKey", "aaa");
ITopic myTopic = Topic.fromTopicArn(this, "MyTopic", "bbb");

BackupVault vault = BackupVault.Builder.create(this, "Vault")
        .encryptionKey(myKey) // Custom encryption key
        .notificationTopic(myTopic)
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
var myKey = Key.FromKeyArn(this, "MyKey", "aaa");
var myTopic = Topic.FromTopicArn(this, "MyTopic", "bbb");

var vault = new BackupVault(this, "Vault", new BackupVaultProps {
    EncryptionKey = myKey,  // Custom encryption key
    NotificationTopic = myTopic
});
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
myKey := kms.Key_FromKeyArn(this, jsii.String("MyKey"), jsii.String("aaa"))
myTopic := sns.Topic_FromTopicArn(this, jsii.String("MyTopic"), jsii.String("bbb"))

vault := backup.NewBackupVault(this, jsii.String("Vault"), &BackupVaultProps{
	EncryptionKey: myKey,
	 // Custom encryption key
	NotificationTopic: myTopic,
})

Properties ​

accessPolicyoptionalPolicyDocumentaccess_policyoptionalPolicyDocumentaccessPolicyoptionalPolicyDocumentAccessPolicyoptionalPolicyDocumentAccessPolicyoptionalPolicyDocument#
A resource-based policy that is used to manage access permissions on the backup vault.

Default: access is not restricted

backupVaultNameoptionalstringbackup_vault_nameoptionalstrbackupVaultNameoptionalStringBackupVaultNameoptionalstringBackupVaultNameoptional*string#
The name of a logical container where backups are stored.

Default: A CDK generated name

Backup vaults are identified by names that are unique to the account used to create them and the AWS Region where they are created.

blockRecoveryPointDeletionoptionalbooleanblock_recovery_point_deletionoptionalboolblockRecoveryPointDeletionoptionalBooleanBlockRecoveryPointDeletionoptionalboolBlockRecoveryPointDeletionoptional*bool= false#
Whether to add statements to the vault access policy that prevents anyone from deleting a recovery point.
encryptionKeyoptionalIKeyRefencryption_keyoptionalIKeyRefencryptionKeyoptionalIKeyRefEncryptionKeyoptionalIKeyRefEncryptionKeyoptionalIKeyRef#
The server-side encryption key to use to protect your backups.

Default: an Amazon managed KMS key

lockConfigurationoptionalLockConfigurationlock_configurationoptionalLockConfigurationlockConfigurationoptionalLockConfigurationLockConfigurationoptionalLockConfigurationLockConfigurationoptionalLockConfiguration#
Configuration for AWS Backup Vault Lock.

Default: AWS Backup Vault Lock is disabled

notificationEventsoptionalBackupVaultEvents[]notification_eventsoptionaltyping.List[BackupVaultEvents]notificationEventsoptionalList<BackupVaultEvents>NotificationEventsoptionalBackupVaultEvents[]NotificationEventsoptional*[]BackupVaultEvents#
The vault events to send.

Default: all vault events if notificationTopic is defined

notificationTopicoptionalITopicnotification_topicoptionalITopicnotificationTopicoptionalITopicNotificationTopicoptionalITopicNotificationTopicoptionalITopic#
A SNS topic to send vault events to.

Default: no notifications

removalPolicyoptionalRemovalPolicyremoval_policyoptionalRemovalPolicyremovalPolicyoptionalRemovalPolicyRemovalPolicyoptionalRemovalPolicyRemovalPolicyoptionalRemovalPolicy= RemovalPolicy.RETAIN#
The removal policy to apply to the vault.

Note that removing a vault that contains recovery points will fail.