Created
May 13, 2023 04:35
-
-
Save wenqiglantz/8548f2ce6509b5faf35e353d92372f4a to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| resource "aws_lambda_function" "lambda_function" { | |
| function_name = var.lambda_function.function_name | |
| runtime = var.lambda_function.runtime | |
| handler = var.lambda_function.handler | |
| memory_size = var.lambda_function.memory_size | |
| timeout = var.lambda_function.timeout | |
| filename = data.archive_file.lambda_zip.output_path | |
| role = aws_iam_role.lambda.arn | |
| tracing_config { | |
| mode = "Active" | |
| } | |
| ephemeral_storage { | |
| size = var.lambda_function.ephemeral_storage | |
| } | |
| publish = true | |
| snap_start { | |
| apply_on = "PublishedVersions" | |
| } | |
| environment { | |
| variables = { | |
| SPRING_CLOUD_FUNCTION_DEFINITION = var.lambda_function.function_name_variable | |
| API_KEY = var.api_key | |
| } | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment