Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dashboard can't login #5

Open
toreydai opened this issue Mar 13, 2020 · 4 comments
Open

dashboard can't login #5

toreydai opened this issue Mar 13, 2020 · 4 comments

Comments

@toreydai
Copy link
Contributor

Kubernetes dashboard portal is ok, but i can't login with token.

@liangruibupt
Copy link
Contributor

liangruibupt commented Mar 14, 2020

As document indicate, please get the login token firstly, then choice token login
#获取登录的token
aws eks get-token --cluster-name ${CLUSTER_NAME} --region ${AWS_REGION} | jq -r '.status.token'

@phoenixyy
Copy link

phoenixyy commented Mar 15, 2020

I met the same issue "Kubernetes dashboard portal is ok, but i can't login with token" when using kube-proxy as a way to publish the Kubernetes dashboard service.

However, I switch to the "LoadBalancer" type of service to publish it. It works.

I suggest that maybe we could change the type to "LoadBalancer"

@liangruibupt
Copy link
Contributor

@phoenixyy May I know your cluster is in public subnet or private subnet?

@liangruibupt
Copy link
Contributor

I just verify again following up the https://github.com/aws-samples/eks-workshop-greater-china/blob/master/china/2020_EKS_Launch_Workshop/%E6%AD%A5%E9%AA%A43-%E9%83%A8%E7%BD%B2%E5%AE%98%E6%96%B9%E7%9A%84KubernetesDashboard.md

  1. worker node on private subnet - success login
kubectl proxy --port=18080 --address=0.0.0.0 --disable-filter=true
http://localhost:18080/api/v1/namespaces/kube-system/services/https:kubernetes-dashboard:/proxy/#!/overview?namespace=default
aws eks get-token --cluster-name gcr-zhy-eksworkshop-private --region cn-northwest-1 | jq -r '.status.token'
  1. worker node on public subnet - success login
kubectl proxy --port=8080 --address=0.0.0.0 --disable-filter=true
http://localhost:8080/api/v1/namespaces/kube-system/services/https:kubernetes-dashboard:/proxy/#!/overview?namespace=default
aws eks get-token --cluster-name gcr-zhy-eksworkshop --region cn-northwest-1 | jq -r '.status.token'

I would suggest check whether you have multiple EKS cluster

kubectl config get-contexts

If yes, please switch to right cluster context

kubectl config use-context xxxx

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants