Terraform module for creating Elasticsearch nodes and various cluster topologies.
module "es" {
source = "git::https://github.com/danisla/terraform-google-elasticsearch.git?ref=v1.0.0"
name = "es-single-node"
region = "us-central1"
zones = ["us-central1-f"]
machine_type = "n1-standard-1"
heap_size = "2g"
master_node = true
data_node = true
disk_size_gb = 50
}
Example single node cluster deployment.
Example multi-node cluster deployment
Similar example as the multi-node cluster deployment but with data nodes outside of a instance group manager.
- Rebuild disk images using the packer repository.
- Set
disk_auto_delete = false
in production to avoid losing data when instances are recreated.
In the multi-node example each node tier can be scaled independently. When scaling UP, simply, increase the number of nodes using the num_nodes
module variable. The new nodes will be created by the Regional Instance Group Manager and the index shards will self-balance.
TBD
TBD