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

Namespaced configmap edit fails for user with RoleBinding to a role that allows it #2535

Closed
aaronthebaron opened this issue Feb 13, 2024 · 1 comment
Labels
bug Something isn't working InProgress Marks an issue has being worked on

Comments

@aaronthebaron
Copy link




Describe the bug
In k9s I cannot edit a configmap which I can edit using kubectl.

This user does not have RBAC permissions to edit all configmaps in the cluster, only the view level ClusterRole, but is the subject of a RoleBinding on a Role within a namespace that has all verbs on certain named configmaps.

To Reproduce
Steps to reproduce the behavior:

  1. Create a namespaced configmap.
  2. Create a Role and RoleBinding that allows verbs for that configmap.
  3. In k9s try to edit the Configmap.
  4. Error will appear.

Historical Documents

can-i result:

kubectl --namespace=api-deps auth can-i patch configmaps/brilliant-classic-configs
yes

k9s logs:

2:11PM ERR current user can't edit resource v1/configmaps
2:11PM DBG TABLE-UPDATER canceled -- "v1/configmaps"

Expected behavior
Should be able to edit the configmap.

Screenshots
N/A

Versions (please complete the following information):

  • OS: OSX
  • K9s: v0.31.8
  • K8s: v1.27.9

Additional context
N/A

@derailed derailed added the bug Something isn't working label Feb 15, 2024
@derailed
Copy link
Owner

@aaronthebaron Great catch! Thank you Aaron!! Will fix in the next drop...

@derailed derailed added the InProgress Marks an issue has being worked on label Feb 15, 2024
derailed added a commit that referenced this issue Feb 16, 2024
placintaalexandru pushed a commit to placintaalexandru/k9s that referenced this issue Apr 3, 2024
* [Bug] fix derailed#2535

* [Bug] fix derailed#2532

* [Bug] fix derailed#2536

* [Bug] fix derailed#2533

* [Bug] fix derailed#2538

* [Maint] cleaning up

* Release notes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working InProgress Marks an issue has being worked on
Projects
None yet
Development

No branches or pull requests

2 participants