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

FWI-5385 Add quiet flag to polaris audit CLI command to suppress 'upload to Insights' prompt #1017

Merged
merged 3 commits into from
Dec 6, 2023

Conversation

jslivka
Copy link
Contributor

@jslivka jslivka commented Dec 5, 2023

This PR addresses #1011

Checklist

  • I have signed the CLA
  • I have updated/added any relevant documentation

Description

Adds the following flag to the polaris audit subcommand:

--quiet                           Suppress the 'upload to Insights' prompt.

What's the goal of this PR?

What changes did you make?

# before
go run main.go audit --audit-path ~/git/fairwinds/charts/stable/insights-agent/insights-manifest.yaml --only-show-failed-tests true --format=pretty

...
Pod insights-insights-agent-delete-jobs
    metadataAndNameMismatched            😬 Warning
        Reliability - Label app.kubernetes.io/name must match metadata.name
    priorityClassNotSet                  😬 Warning
        Reliability - Priority class should be set
    topologySpreadConstraint             😬 Warning
        Reliability - Pod should be configured with a valid topology spread constraint
    automountServiceAccountToken         😬 Warning
        Security - The ServiceAccount will be automounted
    missingNetworkPolicy                 😬 Warning
        Security - A NetworkPolicy should match pod labels and contain applied egress and ingress rules
  Container test
    livenessProbeMissing                 😬 Warning
        Reliability - Liveness probe should be configured
    readinessProbeMissing                😬 Warning
        Reliability - Readiness probe should be configured



🚀 Upload your Polaris findings to Fairwinds Insights to see remediation advice, add teammates, integrate with Slack or Jira, and more:
# after
➜  polaris git:(8.3.0) ✗ go run main.go audit --audit-path ~/git/fairwinds/charts/stable/insights-agent/insights-manifest.yaml --only-show-failed-tests true --format=pretty --quiet

...
Pod insights-insights-agent-delete-jobs
    metadataAndNameMismatched            😬 Warning
        Reliability - Label app.kubernetes.io/name must match metadata.name
    automountServiceAccountToken         😬 Warning
        Security - The ServiceAccount will be automounted
    missingNetworkPolicy                 😬 Warning
        Security - A NetworkPolicy should match pod labels and contain applied egress and ingress rules
    priorityClassNotSet                  😬 Warning
        Reliability - Priority class should be set
    topologySpreadConstraint             😬 Warning
        Reliability - Pod should be configured with a valid topology spread constraint
  Container test
    livenessProbeMissing                 😬 Warning
        Reliability - Liveness probe should be configured
    readinessProbeMissing                😬 Warning
        Reliability - Readiness probe should be configured

What alternative solution should we consider, if any?

Copy link

Fairwinds Insights CI Report

View the Full Report

✅ No new Action Items detected!

@jslivka jslivka added the enhancement Adding additional functionality or improvements label Dec 5, 2023
@jslivka jslivka merged commit 3e96c58 into master Dec 6, 2023
8 checks passed
@jslivka jslivka deleted the FWI-5385/jbs branch December 6, 2023 21:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Adding additional functionality or improvements
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants