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

Add terraform version controls #59

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

jaywcarman
Copy link
Collaborator

Add globals to set minimum and latest Terraform versions.

TERRAFORM_VERSION_MINIMUM: The minimum required version. If there is an
existing binary that matches the minor version and is equal to or
greater than this value then a new binary will not be downloaded.

TERRAFORM_VERSION_LATEST: The version that will be downloaded if there
is no existing binary, or if the existing binary does not meet the
minimum version requirement.

fixes #58

@kavya498
Copy link
Contributor

@jaywcarman , can we get test results of this?

Add globals to set minimum and latest Terraform versions.

TERRAFORM_VERSION_MINIMUM: The minimum required version. If there is an
existing binary that matches the minor version and is equal to or
greater than this value then a new binary will not be downloaded.

TERRAFORM_VERSION_LATEST:  The version that will be downloaded if there
is no existing binary, or if the existing binary does not meet the
minimum version requirement.
@jaywcarman jaywcarman force-pushed the add_terraform_version_controls branch from cad0b2a to b562e5d Compare February 18, 2022 22:07
@jaywcarman
Copy link
Collaborator Author

@kavya498 I reworked this PR to remove the packaging dependency. I tested and verified:

  • If there is no existing terraform executable in the tmp dir then TERRAFORM_VERSION_LATEST will be downloaded and used.
  • Any existing terraform executable that is >= TERRAFORM_VERSION_MINIMUM AND <= TERRAFORM_VERSION_LATEST will not be updated (so user's with the existing 0.12.20 won't see any change, unless we bumped up the tf version min).
  • Any existing terraform executable that is < TERRAFORM_VERSION_MINIMUM OR > TERRAFORM_VERSION_LATEST will be replaced by TERRAFORM_VERSION_LATEST.

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

Successfully merging this pull request may close these issues.

Base Terraform version is old
2 participants