adds yodlee2 accounts

This commit is contained in:
2022-09-30 08:34:13 -07:00
parent e754aea909
commit 8774a3951c
6 changed files with 43 additions and 5 deletions

View File

@@ -3,7 +3,8 @@ variable "task_role_arn" {}
variable "execution_role_arn" {}
variable "stage" {}
variable "job_name" {}
variable "schedule" {}
variable "schedule" { default = "rate(1 hour)" }
variable "use_schedule" { default = true }
variable "cpu" { default = 2048 }
variable "memory" { default = 8192 }
@@ -22,6 +23,7 @@ resource "aws_ecs_task_definition" "background_taskdef" {
}
resource "aws_cloudwatch_event_rule" "schedule" {
count = var.use_schedule ? 1 : 0
name = "${var.job_name}-schedule"
schedule_expression = "${var.schedule}"
}
@@ -29,9 +31,10 @@ resource "aws_cloudwatch_event_rule" "schedule" {
resource "aws_cloudwatch_event_target" "job_target" {
count = var.use_schedule ? 1 : 0
target_id = "${var.job_name}"
arn = var.ecs_cluster
rule = aws_cloudwatch_event_rule.schedule.name
rule = aws_cloudwatch_event_rule.schedule[0].name
role_arn = "arn:aws:iam::679918342773:role/service-role/Amazon_EventBridge_Invoke_ECS_1758992733"
ecs_target {