Using this terrafom module you can launch your public dockerized images in fully managed HA ECS service.
Following components are launched using this module
- Highly available VPC with public private subnets, securtity group, Network ACLs, etc.
- Necessary IAM policies
- Lauch config with autoscaling group
- ECS Cluster , task definition and service
- ELB Endpoint
To launch a new environment create your module defintion as per below example.
module "magnify" {
source = "github.com/dvopsway/terraform_ecs"
access_key = "xxxxxxxxxxxxxxxxxxxxxxxx"
secret_key = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
microservice_name = "magnify"
imagename = "padmakarojha/magnify"
region = "us-east-1"
az = {
zone1 = "us-east-1b"
zone2 = "us-east-1c"
}
vpc_cidr = "10.0.0.0/23"
key_name = "test_key"
}
Once done, run terraform plan
terraform plan
Review you plan and then run terraform apply to create the infra
terraform apply
- Fork it!
- Create your feature branch:
git checkout -b my-new-feature
- Commit your changes:
git commit -am 'Add some feature'
- Push to the branch:
git push origin my-new-feature
- Submit a pull request :D