# Copyright (c) 2012-2022, Mark Peek <mark@peek.org>
# All rights reserved.
#
# See LICENSE file for full license.
#
# *** Do not modify - this file is autogenerated ***
from . import AWSObject, AWSProperty, PropsDictType, Tags
from .validators import boolean
from .validators.efs import Bursting # noqa: F401
from .validators.efs import Elastic # noqa: F401
from .validators.efs import Provisioned # noqa: F401
from .validators.efs import (
provisioned_throughput_validator,
throughput_mode_validator,
validate_backup_policy,
)
[docs]class PosixUser(AWSProperty):
"""
`PosixUser <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-efs-accesspoint-posixuser.html>`__
"""
props: PropsDictType = {
"Gid": (str, True),
"SecondaryGids": ([str], False),
"Uid": (str, True),
}
[docs]class CreationInfo(AWSProperty):
"""
`CreationInfo <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-efs-accesspoint-creationinfo.html>`__
"""
props: PropsDictType = {
"OwnerGid": (str, True),
"OwnerUid": (str, True),
"Permissions": (str, True),
}
[docs]class RootDirectory(AWSProperty):
"""
`RootDirectory <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-efs-accesspoint-rootdirectory.html>`__
"""
props: PropsDictType = {
"CreationInfo": (CreationInfo, False),
"Path": (str, False),
}
[docs]class AccessPoint(AWSObject):
"""
`AccessPoint <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-efs-accesspoint.html>`__
"""
resource_type = "AWS::EFS::AccessPoint"
props: PropsDictType = {
"AccessPointTags": (Tags, False),
"ClientToken": (str, False),
"FileSystemId": (str, True),
"PosixUser": (PosixUser, False),
"RootDirectory": (RootDirectory, False),
}
[docs]class BackupPolicy(AWSProperty):
"""
`BackupPolicy <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-efs-filesystem-backuppolicy.html>`__
"""
props: PropsDictType = {
"Status": (str, True),
}
[docs] def validate(self):
validate_backup_policy(self)
[docs]class FileSystemProtection(AWSProperty):
"""
`FileSystemProtection <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-efs-filesystem-filesystemprotection.html>`__
"""
props: PropsDictType = {
"ReplicationOverwriteProtection": (str, False),
}
[docs]class LifecyclePolicy(AWSProperty):
"""
`LifecyclePolicy <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-efs-filesystem-lifecyclepolicy.html>`__
"""
props: PropsDictType = {
"TransitionToArchive": (str, False),
"TransitionToIA": (str, False),
"TransitionToPrimaryStorageClass": (str, False),
}
[docs]class ReplicationDestination(AWSProperty):
"""
`ReplicationDestination <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-efs-filesystem-replicationdestination.html>`__
"""
props: PropsDictType = {
"AvailabilityZoneName": (str, False),
"FileSystemId": (str, False),
"KmsKeyId": (str, False),
"Region": (str, False),
}
[docs]class ReplicationConfiguration(AWSProperty):
"""
`ReplicationConfiguration <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-efs-filesystem-replicationconfiguration.html>`__
"""
props: PropsDictType = {
"Destinations": ([ReplicationDestination], False),
}
[docs]class FileSystem(AWSObject):
"""
`FileSystem <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-efs-filesystem.html>`__
"""
resource_type = "AWS::EFS::FileSystem"
props: PropsDictType = {
"AvailabilityZoneName": (str, False),
"BackupPolicy": (BackupPolicy, False),
"BypassPolicyLockoutSafetyCheck": (boolean, False),
"Encrypted": (boolean, False),
"FileSystemPolicy": (dict, False),
"FileSystemProtection": (FileSystemProtection, False),
"FileSystemTags": (Tags, False),
"KmsKeyId": (str, False),
"LifecyclePolicies": ([LifecyclePolicy], False),
"PerformanceMode": (str, False),
"ProvisionedThroughputInMibps": (provisioned_throughput_validator, False),
"ReplicationConfiguration": (ReplicationConfiguration, False),
"ThroughputMode": (throughput_mode_validator, False),
}
[docs]class MountTarget(AWSObject):
"""
`MountTarget <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-efs-mounttarget.html>`__
"""
resource_type = "AWS::EFS::MountTarget"
props: PropsDictType = {
"FileSystemId": (str, True),
"IpAddress": (str, False),
"SecurityGroups": ([str], True),
"SubnetId": (str, True),
}