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

Quiet mode #29061

Open
mcandre opened this issue Jun 29, 2021 · 6 comments
Open

Quiet mode #29061

mcandre opened this issue Jun 29, 2021 · 6 comments
Labels
enhancement new new issue not yet triaged

Comments

@mcandre
Copy link

mcandre commented Jun 29, 2021

Current Terraform Version

$ terraform version
Terraform v1.0.0
on darwin_amd64
+ provider registry.terraform.io/hashicorp/aws v3.47.0

Use-cases

Reduce the I/O noise of a typical Terraform run.

Attempted Solutions

Ansible is often quieter than Terraform, however the Ansible Galaxy playbooks may not always be as well maintained as Terraform modules.

Proposal

Offer a -quiet flag that skips the great mass of "Still creating...", "Still destroying..." messages that Terraform spits out.

Let's try harder to follow UNIX conventions, so that our tools run essentially silently, and only talk when explicitly asked or in the event of an error. DevOps tools in the Go world tend to follow this convention as well.

When working locally, this issue is more cosmetic. It's about how the noise distracts from higher level activities.

When working remotely, the I/O waste actually costs more to operate, in terms of transmission and storage fees.

At the very least, let's trim down the async in-progress noise. There isn't any actual information in these extra messages that the normal "Creating...", "Creation complete" doesn't already convey. So trimming down the extraneous messages is not only easier to read, but also greener in terms of electricity usage.

@mcandre mcandre added enhancement new new issue not yet triaged labels Jun 29, 2021
@jdb2019
Copy link

jdb2019 commented Aug 8, 2021

How do I 'up-vote' ?

@jdb2019
Copy link

jdb2019 commented Aug 8, 2021

also, offer a 'clean' mode "-s" or "simple" that does not "pretty print" and outputs only plain text.

or: --no-pretty

@akloss-cibo
Copy link

From the lets-make-it-complicated-department, having an in-resource way to control the verbosity would be nice. For some resources, it's normal(ish) for them to take a long time to provision, so getting "still working" messages so often is distracting and unhelpful, but for other resources, where normal provisioning is fast, seeing that it is slow is may give an operator a hint that something is going wrong elsewhere.

In the even-more-complicated-department, if terraform would expose prometheus metrics, I'd scrape 'em during CI.

@mattpopa
Copy link

mattpopa commented Jan 4, 2023

It would be great having a quiet flag for suppressing the reading data/refreshing state output info like we had with refresh=false until terraform 1.2.x.

@adk-swisstopo
Copy link

Specific use case this would resolve: we often have to "diff" a large number of terraform modules (e.g. when modifying a module other modules depend on). With the current "terraform plan" verbosity, it is quite hard to understand whether there is actually any diff and what they are. -detailed-exitcode helps a bit but scrolling up through endless debug output is still a pain to understand what the diffs are. It would be much nicer if "terraform plan" could print only diff on stdout. Anything else could either be not printed or printed on stderr where it's easy to filter out.

@crw
Copy link
Contributor

crw commented Mar 4, 2025

Thanks for this feature request! If you are viewing this issue and would like to indicate your interest, please use the 👍 reaction on the issue description to upvote this issue. We also welcome additional use case descriptions. Thanks again!

(Adding this late to help latecomers to this issue get this prioritized.)

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

No branches or pull requests

6 participants