Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Applying enterprise consul_license resource results in error #223

Closed
acornies opened this issue Aug 28, 2020 · 1 comment · Fixed by #227
Closed

Applying enterprise consul_license resource results in error #223

acornies opened this issue Aug 28, 2020 · 1 comment · Fixed by #227

Comments

@acornies
Copy link

acornies commented Aug 28, 2020

While applying the consul_license enterprise resource, Terraform fails on read of the license schema. However, the license does get applied successfully according to Consul.

From what I can tell, this is due to a mismatched schema for some properties of the license response from Consul.

Terraform Version

Terraform v0.13.1-dev (testing w/ unrelated salt-masterless changes on hashicorp/terraform#25944)

  • provider registry.terraform.io/hashicorp/consul v2.9.0

Affected Resource(s)

  • consul_license

Debug Output

2020/08/28 11:33:02 [DEBUG] module.consul_ent.consul_license.hce: apply errored, but we're indicating that via the Error pointer rather than returning it: failed to set 'flags': flags.modules: '' expected type 'string', got unconvertible type '[]interface {}'
2020/08/28 11:33:02 [ERROR] eval: *terraform.EvalApplyPost, err: failed to set 'flags': flags.modules: '' expected type 'string', got unconvertible type '[]interface {}'
2020/08/28 11:33:02 [ERROR] eval: *terraform.EvalSequence, err: failed to set 'flags': flags.modules: '' expected type 'string', got unconvertible type '[]interface {}'
2020-08-28T11:33:02.555-0400 [DEBUG] plugin: plugin process exited: path=.terraform/plugins/terraform.tucows.net/tucowsinc/openstackfwaasv2/0.2.0/darwin_amd64/terraform-provider-openstackfwaasv2 pid=89680
2020-08-28T11:33:02.555-0400 [DEBUG] plugin: plugin exited

Error: failed to set 'flags': flags.modules: '' expected type 'string', got unconvertible type '[]interface {}'

  on modules/consul_ent/main.tf line 7, in resource "consul_license" "hce":
   7: resource "consul_license" "hce" {

Expected Behavior

The consul license should be correctly applied and no error is returned from Terraform.

Actual Behavior

The consul license is applied successfully but Terraform errors.

Steps to Reproduce

Use a license with the most amount of features for Consul enterprise v1.8.3+ent

  1. terraform apply

Important Factoids

Our enterprise Consul license has the highest tier of features.

References

N/A

@remilapeyre
Copy link
Contributor

Thanks for reporting this issue @acornies, I will have a look quickly.

remilapeyre added a commit to remilapeyre/terraform-provider-consul that referenced this issue Sep 9, 2020
Since this just removes an attribute it does not need a StateUpgrader.

Closes hashicorp#223
remilapeyre added a commit that referenced this issue Sep 14, 2020
Since this just removes an attribute it does not need a StateUpgrader.

Closes #223
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants