LifecyclePolicy

class aws_cdk.aws_efs.LifecyclePolicy(value)

Bases: Enum

EFS Lifecycle Policy, if a file is not accessed for given days, it will move to EFS Infrequent Access or Archive storage.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-efs-filesystem.html#cfn-elasticfilesystem-filesystem-lifecyclepolicies

ExampleMetadata:

infused

Example:

file_system = efs.FileSystem(self, "MyEfsFileSystem",
    vpc=ec2.Vpc(self, "VPC"),
    lifecycle_policy=efs.LifecyclePolicy.AFTER_14_DAYS,  # files are not transitioned to infrequent access (IA) storage by default
    performance_mode=efs.PerformanceMode.GENERAL_PURPOSE,  # default
    out_of_infrequent_access_policy=efs.OutOfInfrequentAccessPolicy.AFTER_1_ACCESS,  # files are not transitioned back from (infrequent access) IA to primary storage by default
    transition_to_archive_policy=efs.LifecyclePolicy.AFTER_14_DAYS,  # files are not transitioned to Archive by default
    replication_overwrite_protection=efs.ReplicationOverwriteProtection.ENABLED
)

Attributes

AFTER_14_DAYS

After 14 days of not being accessed.

AFTER_180_DAYS

After 180 days of not being accessed.

AFTER_1_DAY

After 1 day of not being accessed.

AFTER_270_DAYS

After 270 days of not being accessed.

AFTER_30_DAYS

After 30 days of not being accessed.

AFTER_365_DAYS

After 365 days of not being accessed.

AFTER_60_DAYS

After 60 days of not being accessed.

AFTER_7_DAYS

After 7 days of not being accessed.

AFTER_90_DAYS

After 90 days of not being accessed.