diff --git a/main.tf b/main.tf index 381dd07..71fa7b0 100644 --- a/main.tf +++ b/main.tf @@ -145,8 +145,8 @@ resource "aws_elasticsearch_domain" "default" { instance_count = var.instance_count instance_type = var.instance_type dedicated_master_enabled = var.dedicated_master_enabled - dedicated_master_count = var.dedicated_master_count - dedicated_master_type = var.dedicated_master_type + dedicated_master_count = var.dedicated_master_enabled ? var.dedicated_master_count : null + dedicated_master_type = var.dedicated_master_enabled ? var.dedicated_master_type : null zone_awareness_enabled = var.zone_awareness_enabled warm_enabled = var.warm_enabled warm_count = var.warm_enabled ? var.warm_count : null