elastic / terraform-provider-elasticstack

Terraform provider for Elastic Stack
https://registry.terraform.io/providers/elastic/elasticstack/latest/docs
Apache License 2.0
170 stars 92 forks source link

Improve error reporting when the provider is not correctly configured. #355

Open tobio opened 1 year ago

tobio commented 1 year ago

From https://github.com/elastic/terraform-provider-elasticstack/issues/354

We can't enforce these endpoints are configured within the provider schema since it should be possible to configure only the components you're using, however we should validate that the built clients have a valid base configuration (e.g at least one endpoint, and auth scheme).

georgms commented 9 months ago

As noted in #354 the kibana endpoints are required when configuring connectors or actions. If these are omitted, the error message is something like unsupported schema: "" so completely useless. Took me half a day to figure out that I was missing the kibana endpoints. It would be fantastic if you can improve the error reporting as discussed here. Thank you!