diff --git a/docs/adrs/01-pick-lamba-handler-name.md b/docs/adrs/01-pick-lamba-handler-name.md new file mode 100644 index 0000000..f840829 --- /dev/null +++ b/docs/adrs/01-pick-lamba-handler-name.md @@ -0,0 +1,22 @@ +# 1. Pick the Custom Domain Lambda Handler Name + +Date: 2024-01-19 + +## Status + +Accepted + +## Context + +Per the AWS documentation for [Lambda function handlers in Python](https://docs.aws.amazon.com/lambda/latest/dg/python-handler.html?icmpid=docs_lambda_help), we need to ensure that what Terraform defines for the handler when it create the Lambda function matches up with what the developer uses for a file name and function name in the dependent application repository. + +See ADR#8 in [mitlib-tf-workloads-libraries-website](https://github.com/MITLibraries/mitlib-tf-workloads-libraries-website) which says the exact same thing. + +## Decision + +1. The "custom domain" Lambda function handler is `lambda_handler`. +2. The "custom domain" Lambda function filename in which the handler function lives is `lambda_edge.py`. + +## Consequences + +If anyone decides to rename Python files in this repo, then the definition of the Lambda function in the [mitlib-tf-workloads-libraries-website](https://github.com/MITLibraries/mitlib-tf-workloads-libraries-website) repo might need to be udpated.