doc: update token instruction

Update README to include instruction for creating token for Kubernetes v1.22+
This commit is contained in:
Jeff Ng
2023-03-29 12:54:31 +08:00
committed by GitHub
parent ff0b9eb5b1
commit 3616f606d1

View File

@@ -101,12 +101,16 @@ kubectl create serviceaccount skooner-sa
# Give that service account root on the cluster
kubectl create clusterrolebinding skooner-sa --clusterrole=cluster-admin --serviceaccount=default:skooner-sa
# For Kubernetes v1.21 or lower
# Find the secret that was created to hold the token for the SA
kubectl get secrets
# Show the contents of the secret to extract the token
kubectl describe secret skooner-sa-token-xxxxx
# For Kubernetes v1.22 or higher
kubectl create token skooner-sa
```
Copy the `token` value from the secret, and enter it into the login screen to access the dashboard.