kdash
kdash copied to clipboard
Context with no permission to enumerate other namespaces will not enumerate pods
Describe the bug If the user of the active context does not have permission to enumerate other namespaces, etc., errors will be shown and no pods are listed in the current namespace even though it's permitted for the user
To Reproduce Steps to reproduce the behavior or a screencast
- select a context with permission restrictions
Expected behavior
- resources that the user have permission to view will be shown
- resources that the user does not have permission to view will not be shown (perhaps a 'no permission' message be presented)
Desktop (please complete the following information): MacOS 11.5 iTerm2 3.4.8 Bash 5.1.8 Kubectl Client Version 1.21.0 Kubectl Server Version 1.19 KDash version 0.2.3 Installed from homebrew
Thaks for the report. I think I need to check permission and fail gracefully in this case
This would be a nice fix. In my case, I have the namespace I have permission for in my kubeconfig contexts definition. Would it be sufficient for kdash to simply check that and if it's defined, just use that namespace and skip the get namespace cmd?