Ask the API server whether an action is allowed.
Section: Debugging Pods and Containers
Check RBAC permission
bash
bash
kubectl auth can-i create deployments -n paymentsExplanation
Ask the API server whether an action is allowed.
Learn the surrounding workflow
Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.
Related commands
Same sheet · prioritizing Debugging Pods and Containers
Check permission as another identity
Test RBAC from another subject's perspective.
Add ephemeral debug container
Inject an ephemeral debug container into a running pod.
Describe failed pods by selector
Inspect all matching pods for failure clues.