How can I do this exercise?( *You shouldn't have to copy and paste the token eac . . .

madhusmita:
How can I do this exercise?(
You shouldn’t have to copy and paste the token each time. The Dashboard application is programmed to read token from the secret mount location. However currently, the ‘default’ service account is mounted. Update the deployment to use the newly created ServiceAccount

Edit the deployment to change ServiceAccount from ‘default’ to ‘dashboard-sa’

I generated the pod-definition.yaml file from the command

controlplane $ kubectl get pod web-dashboard-548dff47bd-jvf5t -o yaml > pod-definition.yaml

and edited the serviceAccountName field to ‘dashboard-sa’, but it is failing.

ömer sönmez:
in stead of single pod, could you try exporting deployment web-dashboard as yaml and update its pod template for new service account?

madhusmita:
Thanks, it worked.

Can you please provide the solution steps here?

kubectrl edit pod “podname”
Please chnage service account name from default to dashboard-sa and than replace --force -f /temp/… .yaml