Class: AWSCDK::Backup::CfnBackupVaultProps

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
backup/cfn_backup_vault_props.rb

Overview

Properties for defining a CfnBackupVault.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(backup_vault_name:, access_policy: nil, backup_vault_tags: nil, encryption_key_arn: nil, lock_configuration: nil, notifications: nil) ⇒ CfnBackupVaultProps

Returns a new instance of CfnBackupVaultProps.

Parameters:



15
16
17
18
19
20
21
22
23
24
25
26
27
28
# File 'backup/cfn_backup_vault_props.rb', line 15

def initialize(backup_vault_name:, access_policy: nil, backup_vault_tags: nil, encryption_key_arn: nil, lock_configuration: nil, notifications: nil)
  @backup_vault_name = backup_vault_name
  Jsii::Type.check_type(@backup_vault_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "backupVaultName")
  @access_policy = access_policy
  Jsii::Type.check_type(@access_policy, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJhbnkifQ==")), "accessPolicy") unless @access_policy.nil?
  @backup_vault_tags = backup_vault_tags
  Jsii::Type.check_type(@backup_vault_tags, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoibWFwIn19")), "backupVaultTags") unless @backup_vault_tags.nil?
  @encryption_key_arn = encryption_key_arn
  Jsii::Type.check_type(@encryption_key_arn, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoic3RyaW5nIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5pbnRlcmZhY2VzLmF3c19rbXMuSUtleVJlZiJ9XX19")), "encryptionKeyArn") unless @encryption_key_arn.nil?
  @lock_configuration = lock_configuration.is_a?(Hash) ? ::AWSCDK::Backup::CfnBackupVault::LockConfigurationTypeProperty.new(**lock_configuration.transform_keys(&:to_sym)) : lock_configuration
  Jsii::Type.check_type(@lock_configuration, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19iYWNrdXAuQ2ZuQmFja3VwVmF1bHQuTG9ja0NvbmZpZ3VyYXRpb25UeXBlUHJvcGVydHkifV19fQ==")), "lockConfiguration") unless @lock_configuration.nil?
  @notifications = notifications.is_a?(Hash) ? ::AWSCDK::Backup::CfnBackupVault::NotificationObjectTypeProperty.new(**notifications.transform_keys(&:to_sym)) : notifications
  Jsii::Type.check_type(@notifications, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19iYWNrdXAuQ2ZuQmFja3VwVmF1bHQuTm90aWZpY2F0aW9uT2JqZWN0VHlwZVByb3BlcnR5In1dfX0=")), "notifications") unless @notifications.nil?
end

Instance Attribute Details

#access_policyObject? (readonly)

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



41
42
43
# File 'backup/cfn_backup_vault_props.rb', line 41

def access_policy
  @access_policy
end

#backup_vault_nameString (readonly)

The name of a logical container where backups are stored.

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



36
37
38
# File 'backup/cfn_backup_vault_props.rb', line 36

def backup_vault_name
  @backup_vault_name
end

#backup_vault_tagsHash{String => String}? (readonly)

The tags to assign to the backup vault.



46
47
48
# File 'backup/cfn_backup_vault_props.rb', line 46

def backup_vault_tags
  @backup_vault_tags
end

#encryption_key_arnString, ... (readonly)

A server-side encryption key you can specify to encrypt your backups from services that support full AWS Backup management;

for example, arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab . If you specify a key, you must specify its ARN, not its alias. If you do not specify a key, AWS Backup creates a KMS key for you by default.

To learn which AWS Backup services support full AWS Backup management and how AWS Backup handles encryption for backups from services that do not yet support full AWS Backup , see Encryption for backups in AWS Backup



55
56
57
# File 'backup/cfn_backup_vault_props.rb', line 55

def encryption_key_arn
  @encryption_key_arn
end

#lock_configurationAWSCDK::IResolvable, ... (readonly)

Configuration for AWS Backup Vault Lock .



60
61
62
# File 'backup/cfn_backup_vault_props.rb', line 60

def lock_configuration
  @lock_configuration
end

#notificationsAWSCDK::IResolvable, ... (readonly)

The SNS event notifications for the specified backup vault.



65
66
67
# File 'backup/cfn_backup_vault_props.rb', line 65

def notifications
  @notifications
end

Class Method Details

.jsii_propertiesObject



67
68
69
70
71
72
73
74
75
76
# File 'backup/cfn_backup_vault_props.rb', line 67

def self.jsii_properties
  {
    :backup_vault_name => "backupVaultName",
    :access_policy => "accessPolicy",
    :backup_vault_tags => "backupVaultTags",
    :encryption_key_arn => "encryptionKeyArn",
    :lock_configuration => "lockConfiguration",
    :notifications => "notifications",
  }
end

Instance Method Details

#to_jsiiObject



78
79
80
81
82
83
84
85
86
87
88
89
# File 'backup/cfn_backup_vault_props.rb', line 78

def to_jsii
  result = {}
  result.merge!({
    "backupVaultName" => @backup_vault_name,
    "accessPolicy" => @access_policy,
    "backupVaultTags" => @backup_vault_tags,
    "encryptionKeyArn" => @encryption_key_arn,
    "lockConfiguration" => @lock_configuration,
    "notifications" => @notifications,
  })
  result.compact
end