rbac-view
Like you, a quick search finds you with this tool popping up all over the place. After doing my own research, this is the kind of tool I was hoping to find. A tool that would query the cluster and show me how my roles and access are laid out.
Upon further reading, I realized some of the other tools are only built for either Linux or MacOs. Here’s what I did to get it to work on Windows.
Update binaries to their latest versions
choco upgrade minikube
choco upgrade kubernetes-cli
Install KREW, the Kubernetes Plugin Manager. As always, here’s the source. https://github.com/kubernetes-sigs/krew and the link to get the files are here:
In an administrative command prompt where you downloaded the .exe and .yaml file:
krew.exe install –manifest=krew.yaml
You will need to update your environment variable as listed above and then open a new console window. Then, test it out.
From any directory, run these commands.
kubectl-krew.exe version
kubectl krew version
If you get a “not supported on windows” message, don’t fret. You can uninstall krew simply by deleting the directory
As it states, run
kubectl rbac-view
C:\Users\<your username>\.krew
It will be like it never happened. Try installing it again and see what happens.
Use Krew to install rbac-view
kubectl krew install rbac-view
Open a browser to http://localhost:8800
If we zoom in, we can see our permissions set from a previous exercise.
Simple! To think, I used to try to maintain this with a spreadsheet, but now, I have a lightweight ephemeral tool that I can bring up when I want to see the state of things, and remove when I’m done.
As usual, thanks for reading!