interface BackupSelectionOptions
| Language | Type name |
|---|---|
.NET | Amazon.CDK.AWS.Backup.BackupSelectionOptions |
Java | software.amazon.awscdk.services.backup.BackupSelectionOptions |
Python | aws_cdk.aws_backup.BackupSelectionOptions |
TypeScript (source) | @aws-cdk/aws-backup » BackupSelectionOptions |
Options for a BackupSelection.
Example
declare const plan: backup.BackupPlan;
const myTable = dynamodb.Table.fromTableName(this, 'Table', 'myTableName');
const myCoolConstruct = new Construct(this, 'MyCoolConstruct');
plan.addSelection('Selection', {
resources: [
backup.BackupResource.fromDynamoDbTable(myTable), // A DynamoDB table
backup.BackupResource.fromTag('stage', 'prod'), // All resources that are tagged stage=prod in the region/account
backup.BackupResource.fromConstruct(myCoolConstruct), // All backupable resources in `myCoolConstruct`
]
})
Properties
| Name | Type | Description |
|---|---|---|
| resources | Backup[] | The resources to backup. |
| allow | boolean | Whether to automatically give restores permissions to the role that AWS Backup uses. |
| backup | string | The name for this selection. |
| role? | IRole | The role that AWS Backup uses to authenticate when backuping or restoring the resources. |
resources
Type:
Backup[]
The resources to backup.
Use the helper static methods defined on BackupResource.
allowRestores?
Type:
boolean
(optional, default: false)
Whether to automatically give restores permissions to the role that AWS Backup uses.
If true, the AWSBackupServiceRolePolicyForRestores managed
policy will be attached to the role.
backupSelectionName?
Type:
string
(optional, default: a CDK generated name)
The name for this selection.
role?
Type:
IRole
(optional, default: a new role will be created)
The role that AWS Backup uses to authenticate when backuping or restoring the resources.
The AWSBackupServiceRolePolicyForBackup managed policy
will be attached to this role.

.NET
Java
Python
TypeScript (