Skip to content
This repository has been archived by the owner on Oct 22, 2024. It is now read-only.

Commit

Permalink
Add TF_WARN_OUTPUT_ERRORS to shell out environment
Browse files Browse the repository at this point in the history
This variable is a workaround for
hashicorp/terraform#17655.
  • Loading branch information
ncs-alane committed Jul 25, 2018
1 parent 21c0caf commit 206cc98
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/kitchen/terraform/shell_out.rb
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ def self.run_shell_out(command:, options:)
::Mixlib::ShellOut
.new(
"terraform #{command}",
options.merge(environment: {"TF_IN_AUTOMATION" => "true"})
options.merge(environment: {"TF_IN_AUTOMATION" => "true", "TF_WARN_OUTPUT_ERRORS" => "1"})
)
.tap do |shell_out|
shell_out
Expand Down
2 changes: 1 addition & 1 deletion spec/lib/kitchen/terraform/shell_out_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
end

let :environment do
{"TF_IN_AUTOMATION" => "true"}
{"TF_IN_AUTOMATION" => "true", "TF_WARN_OUTPUT_ERRORS" => "1"}
end

let :logger do
Expand Down

0 comments on commit 206cc98

Please sign in to comment.