Raja g:
Hello All,
I am practicing CKA labs…
Reg: Quiz No: 8 (Practice Test Role Based Access Control)
As per question:
A user dev-user is created. User’s details have been added to the kubeconfig file. Inspect the permissions granted to the user. Check if the user can list pods in the default namespace.
Here I checked in the kubeconfig file (i.e. .kube/config) there was no dev-user added(I could not find the dev-user added)…
Could you correct/help me, if I am looking into wrong place/file…
Where exactly the dev-user added…
Thanks in advance…
Raja g:
Hello Tej,
Thanks for quick response…
I got it… that users will added into kubeconfig file(i.e. .kube/config) under “Users” section – True…
Still did not clear my question here: probably I did not present my question in correct wat…
As per question: A user dev-user
is created. User’s details have been added to the kubeconfig file
But, when I checked into kubeconfig file(.kube/config)… “dev-user” was not added under “Users” section…
So where it was added then…
please see the screen print for the same…
correct me if I am looking into wrong place
Tej_Singh_Rana:
As of now, if you wanna see dev-user
in the kubeconfig file, run the below command.
kubectl config set-credentials dev-user --client-certificate=/etc/kubernetes/pki/users/dev-user/dev-user.crt --client-key=/etc/kubernetes/pki/users/dev-user/dev-user.key --embed-certs=true
Raja g:
Thanks Tej… it worked…
Still im in doubt… as there was no dev-user in kubeconfig file… How it was worked…