Lambda function uses a mounted file system (Amazon EFS or Amazon S3 Files)
What it checks
Lambda function uses a mounted file system (Amazon EFS or Amazon S3 Files)
Where it applies
Terraform: aws_lambda_function
CloudFormation: AWS::Lambda::Function
How to fix it
- If assets are immutable and local copies preserve application semantics, evaluate a ZIP package only within 250 MB uncompressed including layers and custom runtimes, or an Image package within 10 GB uncompressed including all layers. For S3 caching, grant S3 access and set ephemeral_storage { size } / EphemeralStorage.Size to fit assets plus working space: default 512 MB, maximum 10,240 MB. Keep shared mutable data in shared storage; /tmp is private per execution environment.
- For an EFS mount, inspect the file system's throughput mode and network access. For Amazon S3 Files, review its service-specific access and caching configuration. Compare measured on-demand initialization and provisioned concurrency behavior before claiming a latency or cost benefit from migration.
Frameworks
- AWS Well-Architected PERF.3
These mappings are advisory, not an attestation of compliance.