A Production ready ECS cluster of elasticsearch 1.7, Use docker on local and use terraform module to deploy on ECS
For local development have a look at this example docker-compose.yml config:
elasticsearch:
build: ./elasticsearch/
mem_limit: 512m
ports:
- "9200:9200"
- "9300:9300"
volumes:
- ./elasticsearch/es_data:/usr/share/elasticsearch/data
For deployment on AWS, I had included terraform code to create:
- EFS: Used as a persistent storage for our ElasticSearch Cluster
- ECS: Cluster and Task definition
- ELB: Internal ELB use with private subnet
- SG
- IAM Role
Look terraform/es/variables.tf
Change name, image_elasticsearch, vpc_id, etc as per your need. The image name provided is being used by me which is hosted on ECR.
Add more description