Skip to content

CreateAccessPoint

Source: src/AWS/EFS/CreateAccessPoint.ts

Runtime binding for the CreateAccessPoint operation (IAM actions elasticfilesystem:CreateAccessPoint on the file system ARN and elasticfilesystem:TagResource for tag-on-create).

Creates an access point into the bound FileSystem at runtime — the multi-tenant pattern where each tenant gets its own POSIX identity and root directory carved out of one file system. ClientToken makes the create idempotent; a repeated identical create surfaces the typed AccessPointAlreadyExists. For statically-known access points, prefer the AccessPoint resource. Provide the implementation with Effect.provide(AWS.EFS.CreateAccessPointHttp).

const createAccessPoint = yield* AWS.EFS.CreateAccessPoint(files);
const accessPoint = yield* createAccessPoint({
ClientToken: `tenant-${tenantId}`,
PosixUser: { Uid: 1000, Gid: 1000 },
RootDirectory: {
Path: `/tenants/${tenantId}`,
CreationInfo: { OwnerUid: 1000, OwnerGid: 1000, Permissions: "750" },
},
});