-
Notifications
You must be signed in to change notification settings - Fork 9.2k
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
AWS Account ID not allowed - Leading 0 account number #15310
Comments
Hi, I am seeing a variation of this too. I was able to work around it in one instance by quoting the account number. The issue I am seeing is that the leading zero is being silently dropped. Code to reproduce:-
Plan output:-
Terraform v0.13.2 The real account number is 011111111111 (well obviously not but I'm not pasting the real one here) Debug output - https://gist.github.com/trevorrea/5f27c9ccae96b94eb6704aca0367cddd Thanks, |
Thanks for the update, @robh-wirehive. Since @trevorrea, I suspect a similar problem in your case. |
Hi @gdavison - thanks for the reply. I can confirm that setting the |
Great news! |
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 feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks! |
Community Note
Terraform CLI and Terraform AWS Provider Version
Affected Resource(s)
Terraform Configuration Files
I have a setup which has worked successfully for 35/37 accounts i have created the structure for, but the only two accounts which are causing me issue contain a leading 0 in their account number, so wonder if there is something perculiur with terraform not recognising leading 0's in the number variable data type when passed to a provider
Tree Structure
File where the variables are assigned vales
File where the role is declared
File where the module will locate the modules tf
File where the provider is declared
Debug Output
Panic Output
Expected Behavior
Able to perform a plan successfully, which will give an output of the resources to be created
Actual Behavior
Received the following error code
Steps to Reproduce
Try to perform a plan with an account that has a leading 0 as a number data type
Pass the role_arn (string), and account_number (number) to the module/configuration.tf
Important Factoids
References
The text was updated successfully, but these errors were encountered: