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

Automatically populate usage with supported IaC providers, versions, and policies #336

Merged
merged 8 commits into from
Sep 18, 2020

Conversation

kanchwala-yusuf
Copy link
Contributor

@kanchwala-yusuf kanchwala-yusuf commented Sep 18, 2020

This PR removes the need to manually update the usage whenever a new policy or iac support is added.

Updated usage looks like:

Terrascan

Detect compliance and security violations across Infrastructure as Code to mitigate risk before provisioning cloud native infrastructure.

Usage:
  terrascan scan [flags]

Flags:
      --config-only          will output resource config (should only be used for debugging purposes)
  -h, --help                 help for scan
  -d, --iac-dir string       path to a directory containing one or more IaC files (default ".")
  -f, --iac-file string      path to a single IaC file
  -i, --iac-type string      iac type (k8s, terraform)
      --iac-version string   iac version (k8s: v1, terraform: v12)
  -p, --policy-path string   policy path directory
  -t, --policy-type string   <required> policy type (aws, azure, gcp, k8s)

Global Flags:
  -c, --config-path string   config file path
  -l, --log-level string     log level (debug, info, warn, error, panic, fatal) (default "info")
  -x, --log-type string      log output type (console, json) (default "console")
  -o, --output string        output type (json, yaml, xml) (default "yaml")

@sonarcloud
Copy link

sonarcloud bot commented Sep 18, 2020

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities (and Security Hotspot 0 Security Hotspots to review)
Code Smell A 1 Code Smell

No Coverage information No Coverage information
0.0% 0.0% Duplication

@kanchwala-yusuf kanchwala-yusuf changed the title Auto pickup supportedtypes auto pick up supported iac providers, versions and policies Sep 18, 2020
@codecov
Copy link

codecov bot commented Sep 18, 2020

Codecov Report

Merging #336 into master will increase coverage by 0.54%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #336      +/-   ##
==========================================
+ Coverage   60.87%   61.42%   +0.54%     
==========================================
  Files          56       56              
  Lines        1053     1068      +15     
==========================================
+ Hits          641      656      +15     
  Misses        346      346              
  Partials       66       66              
Impacted Files Coverage Δ
pkg/cli/scan.go 64.28% <100.00%> (ø)
pkg/iac-providers/providers.go 100.00% <100.00%> (ø)
pkg/policy/cloud-providers.go 100.00% <100.00%> (ø)

@cesar-rodriguez cesar-rodriguez changed the title auto pick up supported iac providers, versions and policies Automatically populate usage with supported IaC providers, versions, and policies Sep 18, 2020
@cesar-rodriguez cesar-rodriguez merged commit 0b22a65 into master Sep 18, 2020
@cesar-rodriguez cesar-rodriguez deleted the auto-pickup-supportedtypes branch September 18, 2020 20:12
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.

2 participants