turbot / steampipe

Zero-ETL, infinite possibilities. Live query APIs, code & more with SQL. No DB required.
https://steampipe.io
GNU Affero General Public License v3.0
6.84k stars 264 forks source link

Ability to exclude non applicable checks from a report #1759

Closed pdecat closed 1 year ago

pdecat commented 2 years ago

Is your feature request related to a problem? Please describe.

When generating a compliance report with steampipe check all, the report can contain many empty sections about resources that are not used at all in the current context.

Describe the solution you'd like

I'd like to be able to pass a command-line parameter to steampipe check to omit empty sections from the generated report. Maybe --omit-empty-sections or --omit-empty-checks.

Describe alternatives you've considered

Identify which resources are used in the context, and use steampipe check check1 check2 ... instead of steampipe check all but that can be tedious and error-prone.

Additional context

Example of a report generated against the terraform https://github.com/terraform-aws-modules/terraform-aws-lambda/ community module using the https://hub.steampipe.io/mods/turbot/terraform_aws_compliance mod: all-20220330-145142.pdf

binaek commented 1 year ago

This can be achieved with custom check output templates.

https://steampipe.io/docs/develop/writing-control-output-templates