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

Logging levels need clarifying #742

Open
estar-platform-team opened this issue Feb 5, 2025 · 4 comments
Open

Logging levels need clarifying #742

estar-platform-team opened this issue Feb 5, 2025 · 4 comments

Comments

@estar-platform-team
Copy link

Hello,

I'd like to request the documentation and code comments regarding logging levels to be more detailed, as It's not clear how to enable debug logs to help troubleshooting for any pod in the chart

the trivy operator recently started crashlooping for us in 3 differnent and I'm unable to find out why. I tried playing with logging levels but being an integer it's not easy to figure out which value does what. For example, I think in the kyverno plugin, a value of -1 for logginglevel sets it to debug, but that does seem the case for the trivy plugin.

For reference the error events I see for my trivy-plugin pod are

Readiness probe failed: Get "http://IP:8080/vulnr/v1/policies": context deadline exceeded (Client.Timeout exceeded while awaiting headers)
Liveness probe failed: Get "http://IP:8080/vulnr/v1/policies": context deadline exceeded (Client.Timeout exceeded while awaiting headers)

I tried bumping CPU resources in case it was, but no luck. Also increased memory, even if it was not reporting crashing due to OOM, and it did not help either.

Thanks

@fjogeleit
Copy link
Member

thanks for reporting, will take a look on logging improvements and documentation

@estar-platform-team
Copy link
Author

thanks for reporting, will take a look on logging improvements and documentation

in the meantime, could you let us know how to enable debug logging for the trivy plugin?

@fjogeleit
Copy link
Member

Hey,

I fixed the debug logging for CVE and GHA requests and did a general improvement of the list request. Can you set plugin.trivy.image.tag to 0.4.1 and check if this helps?

Otherwise I also fixed the debug logging for external requests, you should be able to enabled them with:

plugin:
  trivy:
    logging:
      logLevel: -1
      api: true

@estar-platform-team
Copy link
Author

thanks, that worked. My trivy plugin keeps crashing, I will submit another issue for that

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

No branches or pull requests

2 participants