I am trying to access the kubernetes Dashboard using the config file. From the authentication when I select config file its giving ‘Not enough data to create auth info
1 - Assuming one has followed the directions to setup the dashboard here. https://docs.aws.amazon.com/eks/latest/userguide/dashboard-tutorial.html
2 - And your normal kubectl access works from the command line (i.e. kubectl get services).
3 - And you are able to login manually to the Dashboard with the token (with kubectl -n kube-system describe secret ...), by using copy/paste.
4 - But now you want to use the "Kubeconfig" (instead of "Token") option to login to the Dashboard, for simplicity.
Solution:
Here is what it should look like...
apiVersion: v1
clusters:
- cluster:
certificate-authority-data: REDACTED
server: https://kubemaster:6443
name: kubernetes
contexts:
- context:
cluster: kubernetes
user: kubernetes-admin
name: kubernetes-admin@kubernetes
current-context: kubernetes-admin@kubernetes
kind: Config
preferences: {}
users:
- name: kubernetes-admin
user:
client-certificate-data: REDACTED
client-key-data: REDACTED
token: PUT_YOUR_TOKEN_HERE_THAT_YOU_USED_TO_MANUALLY_LOGIN