Skip to content

Commit 9a5769f

Browse files
authored
Merge pull request #6 from ONS-Innovation/KEH-922-timeout-prevention
KEH-922 | BUG: Timeout Prevention
2 parents d32ae69 + 8e64ac3 commit 9a5769f

3 files changed

Lines changed: 10 additions & 1 deletion

File tree

terraform/service/env/dev/example_tfvars.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@ env_name = "sdp-dev"
77
lambda_name = "github-repository-archive-script"
88
lambda_version = "v0.0.1"
99
lambda_arch = "x86_64"
10-
lambda_timeout = 300
10+
lambda_timeout = 900
11+
lambda_memory = 512
1112
schedule = "cron(0 6 ? * 2 *)"
1213
github_org = "ONS-Innovation"
1314
github_app_client_id = "123456789"

terraform/service/main.tf

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@ resource "aws_lambda_function" "lambda_function" {
4141
mode = "Active"
4242
}
4343

44+
memory_size = var.lambda_memory
45+
4446
role = aws_iam_role.lambda_function_role.arn
4547

4648
environment {

terraform/service/variables.tf

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,12 @@ variable "github_app_client_id" {
7171
type = string
7272
}
7373

74+
variable "lambda_memory" {
75+
description = "AWS Lambda Memory Size in MB"
76+
type = number
77+
default = 128
78+
}
79+
7480
variable "region" {
7581
description = "AWS region"
7682
type = string

0 commit comments

Comments
 (0)