Skip to content

Commit e4d2ab1

Browse files
authored
Move warmer to terraform module (#223)
1 parent b05826e commit e4d2ab1

File tree

7 files changed

+58
-105
lines changed

7 files changed

+58
-105
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,6 @@ dev_health_check:
154154
prod_health_check:
155155
curl -f https://core.acm.illinois.edu/api/v1/healthz && curl -f https://core.acm.illinois.edu
156156

157-
lock_terraform: init_terraform
157+
lock_terraform:
158158
terraform -chdir=terraform/envs/qa providers lock -platform=windows_amd64 -platform=darwin_amd64 -platform=darwin_arm64 -platform=linux_amd64 -platform=linux_arm64
159159
terraform -chdir=terraform/envs/prod providers lock -platform=windows_amd64 -platform=darwin_amd64 -platform=darwin_arm64 -platform=linux_amd64 -platform=linux_arm64

cloudformation/main.yml

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -65,15 +65,6 @@ Mappings:
6565
- subnet-0cbe89f6ab2665610
6666

6767
Resources:
68-
AppLambdaWarmer:
69-
Type: AWS::Serverless::Application
70-
DependsOn:
71-
- AppApiLambdaFunction
72-
Properties:
73-
Location: ./warmer.yml
74-
Parameters:
75-
FunctionToWarm: !Sub ${ApplicationPrefix}-lambda
76-
7768
AppSecurityRoles:
7869
Type: AWS::Serverless::Application
7970
Properties:

cloudformation/warmer.yml

Lines changed: 0 additions & 95 deletions
This file was deleted.

terraform/envs/prod/.terraform.lock.hcl

Lines changed: 23 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

terraform/envs/prod/main.tf

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,3 +77,8 @@ resource "aws_dynamodb_table" "app_audit_log" {
7777
enabled = true
7878
}
7979
}
80+
81+
module "lambda_warmer" {
82+
source = "github.com/acm-uiuc/terraform-modules/lambda-warmer?ref=v0.1.1"
83+
function_to_warm = "infra-core-api-lambda"
84+
}

terraform/envs/qa/.terraform.lock.hcl

Lines changed: 23 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

terraform/envs/qa/main.tf

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ terraform {
1616
}
1717
}
1818

19+
1920
provider "aws" {
2021
region = "us-east-1"
2122
default_tags {
@@ -64,3 +65,8 @@ resource "aws_dynamodb_table" "app_audit_log" {
6465
enabled = true
6566
}
6667
}
68+
69+
module "lambda_warmer" {
70+
source = "github.com/acm-uiuc/terraform-modules/lambda-warmer?ref=v0.1.1"
71+
function_to_warm = "infra-core-api-lambda"
72+
}

0 commit comments

Comments
 (0)