Skip to content

fix: Install Terraform once and only log >=500 #4339

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

Merged
merged 1 commit into from
Oct 3, 2022
Merged

Conversation

kylecarbs
Copy link
Member

Fixes #4302.

@kylecarbs kylecarbs self-assigned this Oct 3, 2022
@kylecarbs kylecarbs requested a review from sreya October 3, 2022 17:08
Comment on lines +102 to +115
installTerraform.Do(func() {
installer := &releases.ExactVersion{
InstallDir: options.CachePath,
Product: product.Terraform,
Version: TerraformVersion,
}
installer.SetLogger(slog.Stdlib(ctx, options.Logger, slog.LevelDebug))
options.Logger.Debug(ctx, "installing terraform", slog.F("dir", options.CachePath), slog.F("version", TerraformVersion))
installTerraformExecPath, installTerraformError = installer.Install(ctx)
})
if installTerraformError != nil {
return xerrors.Errorf("install terraform: %w", installTerraformError)
}
options.BinaryPath = execPath
options.BinaryPath = installTerraformExecPath
Copy link
Collaborator

Choose a reason for hiding this comment

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

Why are we calling Serve more than once?

@kylecarbs kylecarbs merged commit 9bc0d06 into main Oct 3, 2022
@kylecarbs kylecarbs deleted the installoutput branch October 3, 2022 20:19
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.

Web URL is too buried in text output
2 participants