Thanks for submitting all of these changes but unfortunately I can't accept so many of them in one pull request.
IAM permissions boundary - this looks good, a PR with just this would probably be accepted.
S3 option - the idea is good but I would prefer to explore whether it can be done without a second aws_lambda_function resource etc. A PR with just this would probably be accepted with discussion and maybe some changes.
Changing this module to require Python 3 and Docker - this probably won't ever be accepted. It would make this module no longer usable in some existing projects. This module already has an optional build_command feature which lets you call a custom script, which can use Docker if desired. There's a Docker example here. Happy to look at whether improvements can/should be made to this, but again it should be a separate PR.
Thanks again, and I hope you understand that we can't make such big and drastic changes to the module in one pull request.
Also I made this terraform-aws-lambda-builder module which might suit your purposes. It allows you to write a build.sh in which you could pip install and then deletes unnecessary files. It runs the build script inside Lambda and stores the result in S3. I think that covers what you've done here but maybe I missed something.
Hi @rdkls,
Thanks for submitting all of these changes but unfortunately I can't accept so many of them in one pull request.
aws_lambda_function
resource etc. A PR with just this would probably be accepted with discussion and maybe some changes.build_command
feature which lets you call a custom script, which can use Docker if desired. There's a Docker example here. Happy to look at whether improvements can/should be made to this, but again it should be a separate PR.Thanks again, and I hope you understand that we can't make such big and drastic changes to the module in one pull request.
Also I made this terraform-aws-lambda-builder module which might suit your purposes. It allows you to write a
build.sh
in which you couldpip install
and then deletes unnecessary files. It runs the build script inside Lambda and stores the result in S3. I think that covers what you've done here but maybe I missed something.