ecs-app-worker

DNXLabs/ecs-app-worker/aws

Terraform Module HCL AWS

This terraform module is an AWS ECS Application Module for Workers without Application Load Balancer (ALB).

Install
module "ecs-app-worker" {
source = "DNXLabs/ecs-app-worker/aws"
version = "2.7.0"
}
plain text: /constructs/tfmod-dnxlabs-ecs-app-worker-aws/install.txt
⭐ Source on GitHub 📦 Registry page
README

terraform-aws-ecs-app-worker ![Lint Status](https://github.com/DNXLabs/terraform-aws-ecs-app-worker/actions) ![LICENSE](https://github.com/DNXLabs/terraform-aws-ecs-app-worker/blob/master/LICENSE) Terraform-aws-ecs-app-worker is an AWS ECS Application Module for Workers without Application Load Balancer(ALB). This module is designed to be used with DNXLabs/terraform-aws-ecs (https://github.com/DNXLabs/terraform-aws-ecs). The following resources will be created: - Cloudwatch Metrics alarm - Provides a CloudWatch Metric Alarm resource. - High memory - High cpu - IAM roles - The cloudwatch event needs an IAM Role to run the ECS task definition. A role is created and a policy will be granted via IAM policy. - ECS task definition - A task definition is required to run Docker containers in Amazo

Inputs (40)
NameTypeDescriptionDefault
namestringName of your ECS service required
vpc_idstringVPC ID to deploy this app to required
memorystringHard memory of the container"512"
autoscaling_minnumberMin number of containers to scale with autoscaling1
autoscaling_scale_in_cooldownnumberCooldown in seconds to wait between scale in events300
task_role_policies_managedlistAWS Managed policies to be added on the task role.[]
subnetsstringThe subnets associated with the task or service. (REQUIRED IF 'LAUCH_TYPE' IS FAnull
network_modestringThe Docker networking mode to use for the containers in the task. The valid valunull
without_capacity_providerboolLaunch service without capacity providerfalse
log_subscription_filter_enabledboolEnable cloudwatch log subscription filterfalse
log_subscription_filter_role_arnstringRole to use for log subscription filter (required when log_subscription_filter_e""
log_subscription_filter_filter_patternstringFilter pattern for log subscription filter""
security_groupsstringThe security groups associated with the task or servicenull
autoscaling_scale_out_cooldownnumberCooldown in seconds to wait between scale out events300
cloudwatch_logs_retentionnumberSpecifies the number of days you want to retain log events in the specified log 120
autoscaling_memoryboolEnables autoscaling based on average Memory trackingfalse
cluster_namestring"Name of existing ECS Cluster to deploy
imagestringDocker image to deploy (can be a placeholder)"dnxsolutions/nginx-hello:latest"
alarm_sns_topicslistAlarm topics to create and alert on ECS service metrics[]
task_role_policieslistCustom policies to be added on the task role.[]
autoscaling_target_cpunumberTarget average CPU percentage to track for autoscaling50
enable_scheduleboolEnables schedule to shut down and start up instances outside business hours.false
Outputs (2)
aws_cloudwatch_log_group_arn
aws_cloudwatch_log_group_name
Resources (12)
aws_appautoscaling_policyaws_appautoscaling_scheduled_actionaws_appautoscaling_targetaws_cloudwatch_log_groupaws_cloudwatch_log_subscription_filteraws_cloudwatch_metric_alarmaws_ecs_serviceaws_ecs_task_definitionaws_iam_policyaws_iam_roleaws_iam_role_policyaws_iam_role_policy_attachment
Details
FrameworkTerraform Module
LanguageHCL
Version2.7.0
Cloud AWS
★ Stars1
Forks7
Total downloads6.1k
Inputs40
Outputs2
Resources12
LicenseApache-2.0
NamespaceDNXLabs
Updated