Avoid specifying warm_count and warm_type when warm_enabled == false
Revert PR #66
Minor cleanups
why
PR #58 allowed unauthenticated access from whitelisted CIDRs, but in the process restricted authenticated access to those IPs as well. This PR make authenticated access not subject to the CIDR restriction.
PR #74 introduced support for UltraWarm clusters, but always set warm_count and warm_type, eve when warm_enabled == false. This caused Terraform to always see the state as needing updating, since the detected state when warm_enabled == false is warm_count = 0 and warm_type unset. The PR leaves them unset to avoid apparent drift.
The kibana_endpoint is not just a domain name, it includes a path component, the end result being something like esdomain-ntzuxwxpuxm7dmxcbpy4slbc4u.us-west-1.es.amazonaws.com/_plugin/kibana/. As such, is not suitable for a DNS record. The plain endpoint is the hostname portion and should be used for DNS. The previous code was correct but misunderstood.
Some working code was nevertheless not the best style, and to the extent this serves as an example, we want the code to be in our preferred style.
what
warm_count
andwarm_type
whenwarm_enabled == false
why
PR #58 allowed unauthenticated access from whitelisted CIDRs, but in the process restricted authenticated access to those IPs as well. This PR make authenticated access not subject to the CIDR restriction.
PR #74 introduced support for UltraWarm clusters, but always set
warm_count
andwarm_type
, eve whenwarm_enabled == false
. This caused Terraform to always see the state as needing updating, since the detected state whenwarm_enabled == false
iswarm_count = 0
andwarm_type
unset. The PR leaves them unset to avoid apparent drift.The
kibana_endpoint
is not just a domain name, it includes a path component, the end result being something likeesdomain-ntzuxwxpuxm7dmxcbpy4slbc4u.us-west-1.es.amazonaws.com/_plugin/kibana/
. As such, is not suitable for a DNS record. The plainendpoint
is the hostname portion and should be used for DNS. The previous code was correct but misunderstood.Some working code was nevertheless not the best style, and to the extent this serves as an example, we want the code to be in our preferred style.