elasticsearch

AckeeCZ/elasticsearch/gcp

Terraform Module HCL GCP

Terraform module for deploying Elasticsearch cluster on GCP

Install
module "elasticsearch" {
source = "AckeeCZ/elasticsearch/gcp"
version = "13.1.0"
}
plain text: /constructs/tfmod-ackeecz-elasticsearch-gcp/install.txt
⭐ Source on GitHub 📦 Registry page
README

Ackee GCE Elasticsearch Terraform module This module is primary written for provisioning of GCE instance from our ES image (https://github.com/AckeeCZ/packer-elasticsearch) It does a few things : Generates GCP IAM Service Account with Storage Admin role for backups and insert it into ES keystore Downloads RAW disk from GCS and create an image from it. (you can generate your own image with Packer using https://github.com/AckeeCZ/packer-elasticsearch) Create SSH key for instance provisioning Create (GCP) firewall rules so GKE "gateway" pods can reach GCE cluster Usage ``hcl module "elasticsearch_prod" { source = "AckeeCZ/elasticsearch/gcp" project = "my-gcp-project" region = "europe-west3" zone = "europe-west3-c" instance_name = "elasticsearch-prod" cluster_name = "elasticsearch" cluster_ipv

Inputs (38)
NameTypeDescriptionDefault
cluster_endpointstringCluster control plane endpoint required
data_disk_sizestringPersistent disk size specified in GB. required
projectstringName of GCP project. required
instance_namestringBase for GCE instances name. Must be unique within GCP project required
cluster_ca_certificatestringPublic CA certificate that is the root of trust for the GKE K8s cluster required
cluster_namestringES cluster name. required
cluster_tokenstringCluster master token, keep always secret! required
regionstringRegion of GCP project. required
es_name_suffix_lengthnumberLength of random generated suffix for ES name8
es_image_creation_timeoutstringTimeout for creating ES image"10m"
add_random_suffixboolAdd random suffix to all resources with possible duplicates if the same module ifalse
backup_repository_createboolIf GCS bucket should be created. Set to false, if you previously created bucket true
health_check_timeout_secnumberHow long (in seconds) to wait before claiming failure. The default value is 5 se5
data_disk_typestringType of disk used as a persistent storage."pd-ssd"
namespacestringK8s namespace used to deploy endpoints and services."production"
health_check_unhealthy_thresholdnumberHow many consecutive failures must occur to mark a VM instance unhealthy.2
heap_sizestringHeap size setting for ES."1800m"
backup_schedulestringBackup schedule in cron format"0 3 * * *"
health_check_interval_secnumberHow often (in seconds) to send a health check. The default value is 5 seconds.5
backend_service_timeout_secnumberHow many seconds to wait for the backend before considering it a failed request.30
node_rolesmap(any)Map of node roles. Index is instance number, starting at zero. If not defined, n{}
root_disk_sizestringPersistent disk size specified in GB."10"
backup_storage_classstringThe storage class you set for an object affects the object's availability and pr"STANDARD"
custom_init_commandsstringAny custom commands which should be run after bootstrapping the Elasticsearch cl""
backup_failed_jobs_history_limitnumberSet retention for failed jobs history5
enable_health_check_loggingboolEnable health check loggingfalse
zonestringZone of GCP project - optional parameter, if not set, the instances will be sprenull
networkstringGCE VPC used for compute instances"default"
Outputs (2)
ilb_dns — DNS name follows GCP internal rule SERVICE_LABEL.FORWARDING_RULE_NAME.il4.REGION.lb.PROJECT_ID.inter
ip_address — The internal IP assigned to the regional forwarding rule.
Resources (17)
google_compute_diskgoogle_compute_firewallgoogle_compute_forwarding_rulegoogle_compute_health_checkgoogle_compute_imagegoogle_compute_instancegoogle_compute_instance_groupgoogle_compute_region_backend_servicegoogle_compute_subnetworkgoogle_project_iam_membergoogle_service_accountgoogle_service_account_keygoogle_storage_bucketkubernetes_cron_job_v1kubernetes_stateful_setrandom_stringtls_private_key
Details
FrameworkTerraform Module
LanguageHCL
Version13.1.0
Cloud GCP
★ Stars10
Forks7
Total downloads19.6k
Inputs38
Outputs2
Resources17
LicenseMIT
NamespaceAckeeCZ
Updated