ScheduleProperty Struct
[Custom snapshot and AMI policies only] Specifies a schedule for a snapshot or AMI lifecycle policy.
Example
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_dlm as dlm } from 'aws-cdk-lib';
const scheduleProperty: dlm.CfnLifecyclePolicy.ScheduleProperty = {
archiveRule: {
retainRule: {
retentionArchiveTier: {
count: 123,
interval: 123,
intervalUnit: 'intervalUnit',
},
},
},
copyTags: false,
createRule: {
cronExpression: 'cronExpression',
interval: 123,
intervalUnit: 'intervalUnit',
location: 'location',
scripts: [{
executeOperationOnScriptFailure: false,
executionHandler: 'executionHandler',
executionHandlerService: 'executionHandlerService',
executionTimeout: 123,
maximumRetryCount: 123,
stages: ['stages'],
}],
times: ['times'],
},
crossRegionCopyRules: [{
encrypted: false,
// the properties below are optional
cmkArn: 'cmkArn',
copyTags: false,
deprecateRule: {
interval: 123,
intervalUnit: 'intervalUnit',
},
retainRule: {
interval: 123,
intervalUnit: 'intervalUnit',
},
target: 'target',
targetRegion: 'targetRegion',
}],
deprecateRule: {
count: 123,
interval: 123,
intervalUnit: 'intervalUnit',
},
fastRestoreRule: {
availabilityZoneIds: ['availabilityZoneIds'],
availabilityZones: ['availabilityZones'],
count: 123,
interval: 123,
intervalUnit: 'intervalUnit',
},
name: 'name',
retainRule: {
count: 123,
interval: 123,
intervalUnit: 'intervalUnit',
},
shareRules: [{
targetAccounts: ['targetAccounts'],
unshareInterval: 123,
unshareIntervalUnit: 'unshareIntervalUnit',
}],
tagsToAdd: [{
key: 'key',
value: 'value',
}],
variableTags: [{
key: 'key',
value: 'value',
}],
};
Properties
archiveRuleoptionalIResolvable | CfnLifecyclePolicy.ArchiveRulePropertyarchive_ruleoptionaltyping.Union[IResolvable, ArchiveRuleProperty]archiveRuleoptionalIResolvableArchiveRuleoptionalIResolvableArchiveRuleoptionalinterface{}#notes
When you specify an archiving rule, snapshots are automatically moved from the standard tier to the archive tier once the schedule's retention threshold is met. Snapshots are then retained in the archive tier for the archive retention period that you specify.
For more information about using snapshot archiving, see Considerations for snapshot lifecycle policies .
copyTagsoptionalboolean | IResolvablecopy_tagsoptionaltyping.Union[bool, IResolvable]copyTagsoptionalBooleanCopyTagsoptionalboolCopyTagsoptionalinterface{}#createRuleoptionalIResolvable | CfnLifecyclePolicy.CreateRulePropertycreate_ruleoptionaltyping.Union[IResolvable, CreateRuleProperty]createRuleoptionalIResolvableCreateRuleoptionalIResolvableCreateRuleoptionalinterface{}#crossRegionCopyRulesoptionalIResolvable | IResolvable | CfnLifecyclePolicy.CrossRegionCopyRuleProperty[]cross_region_copy_rulesoptionaltyping.Union[IResolvable, typing.List[typing.Union[IResolvable, CrossRegionCopyRuleProperty]]]crossRegionCopyRulesoptionalIResolvableCrossRegionCopyRulesoptionalIResolvableCrossRegionCopyRulesoptionalinterface{}#You can't specify cross-Region copy rules for policies that create snapshots on an Outpost or in a Local Zone. If the policy creates snapshots in a Region, then snapshots can be copied to up to three Regions or Outposts.
deprecateRuleoptionalIResolvable | CfnLifecyclePolicy.DeprecateRulePropertydeprecate_ruleoptionaltyping.Union[IResolvable, DeprecateRuleProperty]deprecateRuleoptionalIResolvableDeprecateRuleoptionalIResolvableDeprecateRuleoptionalinterface{}#fastRestoreRuleoptionalIResolvable | CfnLifecyclePolicy.FastRestoreRulePropertyfast_restore_ruleoptionaltyping.Union[IResolvable, FastRestoreRuleProperty]fastRestoreRuleoptionalIResolvableFastRestoreRuleoptionalIResolvableFastRestoreRuleoptionalinterface{}#retainRuleoptionalIResolvable | CfnLifecyclePolicy.RetainRulePropertyretain_ruleoptionaltyping.Union[IResolvable, RetainRuleProperty]retainRuleoptionalIResolvableRetainRuleoptionalIResolvableRetainRuleoptionalinterface{}#tagsToAddoptionalIResolvable | IResolvable | CfnTag[]tags_to_addoptionaltyping.Union[IResolvable, typing.List[typing.Union[IResolvable, CfnTag]]]tagsToAddoptionalIResolvableTagsToAddoptionalIResolvableTagsToAddoptionalinterface{}#These user-defined tags are in addition to the AWS -added lifecycle tags.
variableTagsoptionalIResolvable | IResolvable | CfnTag[]variable_tagsoptionaltyping.Union[IResolvable, typing.List[typing.Union[IResolvable, CfnTag]]]variableTagsoptionalIResolvableVariableTagsoptionalIResolvableVariableTagsoptionalinterface{}#Keys may be any valid Amazon EC2 tag key. Values must be in one of the two following formats: $(instance-id) or $(timestamp) . Variable tags are only valid for EBS Snapshot Management – Instance policies.