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

expected a single file: /tmp/getter3359610012/archive: Downloading terraform Version 1.8.2 #35075

Open
FernandoMiguel opened this issue Apr 24, 2024 · 6 comments
Labels
enhancement new new issue not yet triaged

Comments

@FernandoMiguel
Copy link

FernandoMiguel commented Apr 24, 2024

Terraform Version

terraform version 1.8.2

Terraform Configuration Files

NA

Debug Output

downloading terraform version 1.8.2 at "https://releases.hashicorp.com/terraform/1.8.2/terraform_1.8.2_linux_amd64.zip?checksum=file:https://releases.hashicorp.com/terraform/1.8.2/terraform_1.8.2_SHA256SUMS": expected a single file: /tmp/getter3359610012/archive: Downloading terraform Version 1.8.2

Expected Behavior

for atlantis to pull the correct version of terraform sig

Actual Behavior

we have a recent version of atlantis.
a newer version of terraform came out today, 1.8.2
and when atlantis pulls that version, the SUM seems to fail

Steps to Reproduce

atlantis plan

Additional Context

No response

References

No response

@FernandoMiguel
Copy link
Author

downstream issue runatlantis/atlantis#4472

@jbardin
Copy link
Member

jbardin commented Apr 24, 2024

Hi @FernandoMiguel,

Thanks for filing the issue. Unfortunately the Terraform project does not have absolute control over the packaging and licensing requirements for distribution. The release archives often contain multiple files, and software which fetches the binaries should not expect a single file in the archive. I'm not sure if there's anything we can do from our side, but we can look into it.

@FernandoMiguel
Copy link
Author

Some heads up before this sort of changes would help downstream organisations as well as clients.

We now have to pin back every project to 1.8.1 until atlantis addresses this breaking change.

@radeksimko
Copy link
Member

I'm sorry this change has caused issues and I understand this may not be helpful but this is unfortunately one of those changes we did not anticipate to cause enough issues that would warrant additional heads up. It is however noted in the Changelog and also called out in the announcement on Discourse.

On a more constructive note, we do maintain a library that can aid with installation of HashiCorp products, including Terraform - hc-install and we use it ourselves in a number of places. Atlantis would be welcomed to use it as well. That library does not make assumptions about the archive having just one file. Our enterprise packages (although not relevant for Terraform here specifically) already have multiple files and the API accounts for this too, where the consumers specify a path where the license should be placed.

For Terraform CE, the API would let you specify Dir as a path to the directory where the archive gets unpacked, including terraform binary and the license file. What consumers decide to do with those files after the installation would be up to them. The API does not currently make any further assumptions about those files for non-Enterprise versions.

Just for posterity, go-getter (which is library Atlantis appears to be using) was not designed for this use case of installing products like Terraform, or broadly interacting with releases.hashicorp.com and we do not intend to make changes in that library to accommodate that use case.

I will comment in the linked issue also, for visibility.

@radeksimko radeksimko removed the bug label Apr 24, 2024
@arohter
Copy link

arohter commented Apr 24, 2024

Shame this breaking distribution change was pushed out in a "bugfix" release.

@thomaschaplin
Copy link

correct downstream issue - runatlantis/atlantis#4471

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement new new issue not yet triaged
Projects
None yet
Development

No branches or pull requests

6 participants