-
Notifications
You must be signed in to change notification settings - Fork 9.3k
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
Invalid AWS Region #8040
Comments
It works if I force the region through env variable:
But I don't think it's expected behavior as the region is specified in the provider. |
Still happening for me on |
In the off chance this helps someone who has the same issue but for a different reason, I accidentally had underscores instead of dashes. |
Same issue, i had used underscore instead of -, thanks |
Underscores and dashes in what? |
If I recall correctly I did |
I think there's a new issue now: #9617 |
I had the same problem when using
Error output:
I had to replace the variable with a hard-coded region in order to get it to work. The annoying thing about it is that it appears (far as I can tell) to work just fine when doing plan/apply, and then surprises you with problems if you ever happen to use import. |
faced the same issue during import of resources with terraform v0.12.8 and AWS provider v2.26.0 and v2.27.0 |
Same issue with provider.aws v2.29.0 |
Looks like for import context is initialized with some short circuit. main.tf:
tst/main.tf:
UPD: same error with Terraform v0.12.9 |
I was passing an undeclared and uninitialized Linux variable when running an Apply like so: After setting my variable AWS_REGION with the right region - I was able to proceed with the build. |
faced the same issue terraform = 0.12.20 this works for me 👇
|
Same here with "aws" version 2.40.0 |
The same problem with "profile" too, not only "region". I couldn't do import until hardcoded profile name. Error message:
terraform = 0.12.20, through tfenv. |
This seems to be a deep terraform bug in the way |
I have run into this a few times now - I end up manually editing all the providers in all my modules inside
to
and then |
… local environment variables hashicorp/terraform-provider-aws#8040
I don't know if it is related, but the error is the same, at least. Still happen on v0.15.0 + AWS v3.37.0
If I plan, it goes well
But if I try to destroy
|
I'm also seeing this for the first time today, on 0.15.0. |
I am seeing this issue too, using terraform v0.15.0, and aws v3.37.0. |
It looks like this is a bug upstream in Terraform CLI version 0.15.0 (hashicorp/terraform#28428 / hashicorp/terraform#28444), which could be addressed next Terraform CLI release. |
Works fine when apply, destroy does not work. ╷ However, had to edit the file |
We could circumvent this by configuring the aws provider in the parent module, passing it to deploy-eks module as provider. |
I just build the CLI from main, and it fixes it |
Seeing the same issue. |
BTW, this worked fine with Terraform 0.14.x, but is newly broken with Terraform 0.15.x. |
seems it was fixed in 0.15.1 |
I tried with 0.15.4 and it workd. So; with 0.15.0 I can init and plan, but not destroy. Bug seems fixed in the subsequent patch 🤷♀️ |
Closing this as this appears to have been resolved in an upstream Terraform patch landing in 0.15.1. If I have closed this in error, do let me know and I will reopen. |
seems to have resurfaced in 1.1.7 with aws provider 4.4.0.
|
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. |
Community Note
Terraform Version
Terraform Configuration Files
Debug Output
Plan: https://gist.github.com/scalp42/c847168667233b4bf5b89e79dbaa7c0c
Apply: https://gist.github.com/scalp42/cd7644708890dfed55080c6d870a8b1f
Expected Behavior
Actual Behavior
Steps to Reproduce
terraform plan -out terraform
terraform plan apply terraform
References
This issue relates to the region being asked: hashicorp/terraform#20599
The text was updated successfully, but these errors were encountered: