create_location_efs
async
¶
create_location_efs(
efs_filesystem_arn: EfsFilesystemArn,
ec2_config: Ec2Config,
*,
config_overrides: Optional[AsyncDataSyncClientConfig] = None,
subdirectory: Optional[EfsSubdirectory] = None,
tags: Optional[InputTagList] = None,
access_point_arn: Optional[EfsAccessPointArn] = None,
file_system_access_role_arn: Optional[IamRoleArn] = None,
in_transit_encryption: Optional[EfsInTransitEncryption] = None,
) -> CreateLocationEfsResponse
Creates a transfer location for an Amazon EFS file system. DataSync can use this location as a source or destination for transferring data.
Before you begin, make sure that you understand how DataSync accesses Amazon EFS file systems.
Parameters:
-
subdirectory(Optional[EfsSubdirectory], default:None) –Specifies a mount path for your Amazon EFS file system. This is where DataSync reads or writes data on your file system (depending on if this is a source or destination location).
By default, DataSync uses the root directory (or access point if you provide one by using
AccessPointArn). You can also include subdirectories using forward slashes (for example,/path/to/folder). -
efs_filesystem_arn(EfsFilesystemArn) –Specifies the ARN for your Amazon EFS file system.
-
ec2_config(Ec2Config) –Specifies the subnet and security groups DataSync uses to connect to one of your Amazon EFS file system's mount targets.
-
tags(Optional[InputTagList], default:None) –Specifies the key-value pair that represents a tag that you want to add to the resource. The value can be an empty string. This value helps you manage, filter, and search for your resources. We recommend that you create a name tag for your location.
-
access_point_arn(Optional[EfsAccessPointArn], default:None) –Specifies the Amazon Resource Name (ARN) of the access point that DataSync uses to mount your Amazon EFS file system.
For more information, see Accessing restricted file systems.
-
file_system_access_role_arn(Optional[IamRoleArn], default:None) –Specifies an Identity and Access Management (IAM) role that allows DataSync to access your Amazon EFS file system.
For information on creating this role, see Creating a DataSync IAM role for file system access.
-
in_transit_encryption(Optional[EfsInTransitEncryption], default:None) –Specifies whether you want DataSync to use Transport Layer Security (TLS) 1.2 encryption when it transfers data to or from your Amazon EFS file system.
If you specify an access point using
AccessPointArnor an IAM role usingFileSystemAccessRoleArn, you must set this parameter toTLS1_2.
Raises:
-
InternalException–This exception is thrown when an error occurs in the DataSync service.
-
InvalidRequestException–This exception is thrown when the client submits a malformed request.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_datasync/_services/async_data_sync.py
564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 | |