ecs-scheduled-task
dod-iac/ecs-scheduled-task/aws
Terraform module to create an ECS Scheduled Task
ECS Scheduled Tasks Description This module runs an ECS task in Fargate based on an Event Bridge Rule. Usage ``hcl module "ecs-scheduled-task" { source = "dod-iac/ecs-scheduled-task/aws" name = "task-name" schedule_expression = "cron(30 ? )" ecs_cluster_arn = aws_ecs_cluster.cluster.arn ecs_subnets = var.ecs_subnets vpc_id = var.vpc_id ecr_repository_arn = module.ecr_repo.arn ecr_repository_url = module.ecr_repo.repository_url image_tag = data.aws_ssm_parameter.image_tag.value cloudwatch_log_group_arn = aws_cloudwatch_log_group.main.arn cloudwatch_log_group_name = aws_cloudwatch_log_group.main.name task_role_policy_doc = data.aws_iam_policy_document.task_role_policy_doc.json task_def_env_vars = [ { "name" : "KEYNAME1", "value" : "VALUE1" }, { "name" : "KEYNAME2", "value" : "VALUE2" }, ] ta
| Name | Type | Description | Default |
|---|---|---|---|
| ecr_repository_url | string | The ECR repository URL | required |
| image_tag | string | The image tag to deploy | required |
| vpc_id | string | The vpc ID related to the subnets. | required |
| cloudwatch_log_group_arn | string | The arn of the cloudwatch log group | required |
| cloudwatch_log_group_name | string | The name of the cloudwatch log group | required |
| ecr_repository_arn | string | The ECR repository arn | required |
| ecs_subnets | list(string) | The list of subnets to use for the ECS tasks. | required |
| task_role_policy_doc | string | The IAM policy document used for the task role | required |
| ecs_cluster_arn | string | The ECS cluster arn | required |
| name | string | A unique name for the module | "scheduled-task" |
| ecs_task_cpu | number | 2048 | |
| schedule_expression | string | The schedule to run the task on in AWS cron format. | "cron(30 * * * ? *)" |
| ecs_task_mem | number | 4096 | |
| task_def_env_vars | list(map(string)) | Environment variables for the task definition | [] |
| tags | map | tags for resources | {} |
cloudwatch_target_role_arn — CloudWatch target IAM role arnevent_rule_run_command_arn — CloudWatch event rule run commandarntask_role_arn — ECS task IAM role arntask_execution_role_arn — ECS task execution IAM role arnAzure landing zones Terraform module
Terraform supermodule for the Terraform platform engineering for Azure
Terraform module to deploy landing zone subscriptions (and much more) in Azure
Terraform Module to define a consistent naming convention by (namespace, stage,