Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 

Create Terraform Cloud Agent and ECS Cluster

This example show how you can run the module to launch dedicated ECS cluster for Terraform Cloud Agent. You need to specify VPC ID which is created via separate VPC module.

On this example, the ECS Task role will use arn:aws:iam::aws:policy/ReadOnlyAccess as it's managed policy. You need to modify this to fit your requirements.

Requirements

Name Version
terraform >= 1.5.0
aws >= 5.47.0

Providers

Name Version
aws >= 5.47.0

Modules

Name Source Version
agent_pool ../../ n/a
vpc git::https://github.com/terraform-aws-modules/terraform-aws-vpc 25322b6b6be69db6cca7f167d7b0e5327156a595

Resources

Name Type
aws_availability_zones.available data source

Inputs

Name Description Type Default Required
hcp_terraform_org_name The name of the HCP Terraform organization. string n/a yes
tfe_token Terraform token to be used to create the agent pool. string n/a yes

Outputs

Name Description
agent_pool_id ID of the HCP Terraform or HCP Terraform Enterprise agent pool.
agent_pool_name Name of the HCP Terraform or HCP Terraform Enterprise agent pool.
ecs_service_arn ARN of the ECS service.
ecs_task_arn ARN of the ECS task definition.
ecs_task_revision Revision number of the ECS task definition.
log_stream_prefix Prefix for the CloudWatch log stream.
security_group_id ID of the VPC security group attached to the service.
security_group_name Name of the VPC security group attached to the service.
task_role_arn ARN of the IAM role attached to the task containers.
task_role_name Name of the IAM role attached to the task containers.