이슈,버그

kubectl 실행시 The connection to the server localhost:8080 was refused - did you specify the right host or port? 오류

개발자하나 2023. 2. 8. 17:29

kops로 쿠버네티스 클러스터를 구성하고 난 뒤

마스터노드에서 deployment를 적용하자 The connection to the server localhost:8080 was refused 오류 발생

kubeconfig 설정이 적용 안되서라고 /home/ubuntu/.kube/config는 제대로 생성되어 있음

 

The connection to the server localhost:8080 was refused - did you specify the right host or port?

 

root 유저에서 실행해서 다른 계정의 설정이 적용되지 않음

cp /home/ubuntu/.kube/config /.kube/config
kubectl config view

 

 

https://stackoverflow.com/questions/37921222/kubectl-connection-to-server-was-refused