-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
docs(k8s): a note about k8s credentials #7394
base: main
Are you sure you want to change the base?
Conversation
docs/docs/target/kubernetes.md
Outdated
Trivy must be able to access information about all cluster resources, including pods, deployments etc. | ||
To successfully scan a Kubernetes cluster, `trivy kubernetes` subcommand must be executed under a role that has some specific permissions. | ||
|
||
Without `node collecor` (with flag `--disable-node-collector`) the role must have `list` verb for all resources ("*") inside next API groups: core (""), "apps", "batch","networking.k8s.io", "rbac.authorization.k8s.io": |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
what happens if I have a resource that trivy doesn't have access to? does it fail or the resource isn't scanned? I hope it the latter in which case I would rewrite this section to say that the user is responsible to give trivy permissions to everything it wants to be scanned. having said that there are things like RBAC which we've seen can break the scan so we need to be sure. |
yes, you're right. |
Description
This PR adds a block with permissions that
Trivy k8s
needs for scans:Checklist