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

terraform validate returns The argument "url" is required, but was not set. on child module with no provider block #221

Closed
zjanc opened this issue Sep 14, 2021 · 1 comment

Comments

@zjanc
Copy link

zjanc commented Sep 14, 2021

Hi,

I'm getting The argument "url" is required, but was not set. when running terraform validate on a child module that contains ES resources with no provider block set.

Additional Information:

  • Terraform version: 0.14.11
  • Provider version: 1.6.1

The plan, apply, and import command all work (when run on the calling root module) with the same configuration, it is just validate that is failing.

This error can be fixed by declaring the elasticsearch provider block in the child module but I would like to avoid it to comply with guidelines re: child module provider blocks.

@zjanc zjanc changed the title terraform validate returns The argument "url" is required, but was not set. when passing ES provider to child module terraform validate returns The argument "url" is required, but was not set. on child module with no provider block Sep 14, 2021
@zjanc
Copy link
Author

zjanc commented Sep 14, 2021

Closing this issue, seems this was fixed in 0.15:

hashicorp/terraform#21408

Was fixed on current version by setting a fake ELASTICSEARCH_URL environment variable.

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

No branches or pull requests

1 participant