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 Crashes on Specifying a Provider Version as a Variable #16125

Closed
hylaride opened this issue Sep 19, 2017 · 2 comments
Closed

Terraform Crashes on Specifying a Provider Version as a Variable #16125

hylaride opened this issue Sep 19, 2017 · 2 comments

Comments

@hylaride
Copy link

Hi there,

Having recently just upgraded to TF 0.10, we'd like to have a variable set the provider version so we can increment it separately for our environments, some of which call the provider multiple times. However, TF seems to hard crash on it. I'm expecting that this is a problem with terraform and not the provider as it's crashing before it can extrapolate any version.

Terraform Version

0.10.5

Terraform Configuration Files

variable "aws_provider_version" {
  type = "string"
  default = "0.1.4"
}

provider "aws" {
  version = "${var.aws_provider_version}"
  region  = "${var.region}"
}

Debug Output

https://gist.github.com/hylaride/08db7ebe845675e870f631b1fcd102ad

Crash Output

https://gist.github.com/hylaride/87a9f3c1310f118a2516a005883ac1f7

Expected Behavior

TF should lookup the variable and set it as the version we'd like to have for the aws provider.

Actual Behavior

TF crashed.

Steps to Reproduce

Please list the full steps required to reproduce the issue, for example:

  1. terraform plan

References

Are there any other GitHub issues (open or closed) or Pull Requests that should be linked here? For example:

@apparentlymart
Copy link
Contributor

Hi @hylaride! Sorry for this crash and thanks for reporting it.

I think this is the same as #15742, so I'm going to close this to consolidate discussion over there.

It is intentional that interpolation is not supported here, since it's not possible to change version each time a variable change (installation only happens during init) but indeed it should be a proper error describing the problem rather than a crash.

@ghost
Copy link

ghost commented Apr 6, 2020

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@ghost ghost locked and limited conversation to collaborators Apr 6, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants