Interface AccessPointOptions
- All Superinterfaces:
software.amazon.jsii.JsiiSerializable
- All Known Subinterfaces:
AccessPointProps
- All Known Implementing Classes:
AccessPointOptions.Jsii$Proxy
,AccessPointProps.Jsii$Proxy
@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)",
date="2023-06-19T16:30:40.110Z")
@Stability(Stable)
public interface AccessPointOptions
extends software.amazon.jsii.JsiiSerializable
Options to create an AccessPoint.
Example:
import software.amazon.awscdk.services.ec2.*; import software.amazon.awscdk.services.efs.*; // create a new VPC Vpc vpc = new Vpc(this, "VPC"); // create a new Amazon EFS filesystem FileSystem fileSystem = FileSystem.Builder.create(this, "Efs").vpc(vpc).build(); // create a new access point from the filesystem AccessPoint accessPoint = fileSystem.addAccessPoint("AccessPoint", AccessPointOptions.builder() // set /export/lambda as the root of the access point .path("/export/lambda") // as /export/lambda does not exist in a new efs filesystem, the efs will create the directory with the following createAcl .createAcl(Acl.builder() .ownerUid("1001") .ownerGid("1001") .permissions("750") .build()) // enforce the POSIX identity so lambda function will access with this identity .posixUser(PosixUser.builder() .uid("1001") .gid("1001") .build()) .build()); Function fn = Function.Builder.create(this, "MyLambda") // mount the access point to /mnt/msg in the lambda runtime environment .filesystem(FileSystem.fromEfsAccessPoint(accessPoint, "/mnt/msg")) .runtime(Runtime.NODEJS_16_X) .handler("index.handler") .code(Code.fromAsset(join(__dirname, "lambda-handler"))) .vpc(vpc) .build();
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final class
A builder forAccessPointOptions
static final class
An implementation forAccessPointOptions
-
Method Summary
Modifier and TypeMethodDescriptionstatic AccessPointOptions.Builder
builder()
default Acl
Specifies the POSIX IDs and permissions to apply when creating the access point's root directory.default String
getPath()
Specifies the path on the EFS file system to expose as the root directory to NFS clients using the access point to access the EFS file system.default PosixUser
The full POSIX identity, including the user ID, group ID, and any secondary group IDs, on the access point that is used for all file system operations performed by NFS clients using the access point.Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getCreateAcl
Specifies the POSIX IDs and permissions to apply when creating the access point's root directory.If the root directory specified by
path
does not exist, EFS creates the root directory and applies the permissions specified here. If the specifiedpath
does not exist, you must specifycreateAcl
.Default: - None. The directory specified by `path` must exist.
-
getPath
Specifies the path on the EFS file system to expose as the root directory to NFS clients using the access point to access the EFS file system.Default: '/'
-
getPosixUser
The full POSIX identity, including the user ID, group ID, and any secondary group IDs, on the access point that is used for all file system operations performed by NFS clients using the access point.Specify this to enforce a user identity using an access point.
Default: - user identity not enforced
-
builder
- Returns:
- a
AccessPointOptions.Builder
ofAccessPointOptions
-