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

feat: support auto installing terraform binary #801

Merged
merged 2 commits into from
Feb 20, 2024

Conversation

liu-hm19
Copy link
Contributor

@liu-hm19 liu-hm19 commented Feb 6, 2024

What type of PR is this?

/kind feature

What this PR does / why we need it:

This PR supports automatically installing terraform binary and setting the environment variable of executable path before kusion preview, kusion apply and kusion destroy, if terraform has not been downloaded before.

Here is an example of executing kusion preview twice on a machine where the terraform executable binary has not yet been downloaded.
image
image

Which issue(s) this PR fixes:

Fixes #769

Special notes for your reviewer:

Does this PR introduce a user-facing change?


Additional documentation e.g., design docs, usage docs, etc.:


@liu-hm19 liu-hm19 self-assigned this Feb 6, 2024
@coveralls
Copy link

coveralls commented Feb 6, 2024

Pull Request Test Coverage Report for Build 7796166726

  • -64 of 96 (33.33%) changed or added relevant lines in 3 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.3%) to 76.576%

Changes Missing Coverage Covered Lines Changed/Added Lines %
pkg/cmd/destroy/options.go 6 8 75.0%
pkg/cmd/preview/options.go 6 8 75.0%
pkg/engine/runtime/terraform/install.go 20 80 25.0%
Totals Coverage Status
Change from base Build 7795660400: -0.3%
Covered Lines: 8794
Relevant Lines: 11484

💛 - Coveralls

Copy link
Contributor

@adohe adohe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@adohe adohe merged commit ab28e79 into KusionStack:main Feb 20, 2024
6 checks passed
@github-actions github-actions bot locked and limited conversation to collaborators Feb 20, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Feat: Automatically download Terraform binary if it does not exist
3 participants