Skip to content

fix: Do not expose output from build command in Docker #677

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
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion package.tf
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ data "external" "archive_prepare" {
resource "local_file" "archive_plan" {
count = var.create && var.create_package ? 1 : 0

content = data.external.archive_prepare[0].result.build_plan
content = var.build_in_docker ? sensitive(data.external.archive_prepare[0].result.build_plan) : data.external.archive_prepare[0].result.build_plan
Copy link
Member

Choose a reason for hiding this comment

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

The best solution would be to hide values ONLY if there are secrets inside. Function issensitive became available in Terraform 1.8 but this module expects Terraform 1.0.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Indeed, my first patch was using the issensitive function, but then I checked it only appeared in 1.8. Thank you @antonbabenko!

filename = data.external.archive_prepare[0].result.build_plan_filename
directory_permission = "0755"
file_permission = "0644"
Expand Down