-
Notifications
You must be signed in to change notification settings - Fork 9.6k
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
0.12-rc1 - modules cannot be sourced and installed from git repo #21257
Comments
I get the same error, but for some reason, I get it twice in a row, command exits after 75 seconds:
|
Thanks for reporting this @ilicmilan, and @dirkcjelli for the additional context. This is interesting because I don't believe we changed the install-from-git code in Terraform v0.12, but possibly changes to the upstream library we use for module installation have inadvertently changed the behavior here. We'll investigate what's changed here and get it fixed. Thanks again! |
I also get this, with the line repeated for each reference to the module... I made minimal changes to my terraform such that it would work with 0.11.13 and 0.12. Terraform 0.11.13 managed to checkout via my SSH agent just fine, but get the above with 0.11-beta2 and 0.11-rc1. From my investigation, it worked fine with SSH references to GitHub, but not our cloud-based bitbucket server... My temporary workaround was to move some code to GitHub... I thought it might be defaulting to port 22 for SSH? |
I have the same problem mentionned above with something like: It asks for a password. It seems to completely ignore the specified ssh port and defaults to When modifying the
I then get the aforementioned issue. The workaround is to modify the code as following:
It should then initialize fine. |
It seems that this was broken by hashicorp/go-getter#129, because all of the URLs shared here are matching the heuristic it tries to use to detect "SCP-style" syntax. As a consequence, Because the SCP-style URLs have now been supported for several releases, we unfortunately cannot remove that behavior to fix this, so instead I'm going to investigate whether we can adjust the heuristic to be more conservative and not break explicit port numbers. Unfortunately, the SCP-style syntax support creates an ambiguity, so anything we do here is going to be heuristic:
This ambiguity presumably also exists in Git itself, because Git supports both forms, so I'm going to start by tracking down the relevant logic in Git and see if we can mimic its heuristic more accurately. |
@jocelynthode Thanks for the hint with the ssh-config, works like a charm 👍 |
With #21293 merged, this is now fixed in the master branch. The fix will be included in the forthcoming v0.12.0 final release. Sorry for the accidental regression, everyone! Thanks for sharing that workaround, @jocelynthode! That's a good way to get around this if you'd like to do other testing with v0.12.0-rc1, though you shouldn't need it any more after v0.12.0 final. |
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. |
Terraform Version
Terraform Configuration Files
Debug Output
Expected Behavior
terraform init
should succeedActual Behavior
terraform init
has failedSteps to Reproduce
Use a Git repo and reference it as specified above
terraform init
Additional Context
These git references work in 0.11.x
References
The text was updated successfully, but these errors were encountered: