kubectl 命令报错couldn't get current server API group list: ... connect: connection refused
kubenets在运行时,依赖环境变量。如果所有的服务都是正常的,只是kubectl命令报错,那就是环境变量没有设置导致。一般报错样例如下:
couldn't get current server API group list: Get "http://localhost:8080/api?timeout=32s": dial tcp [::1]:8080: connect: connection refused。The connection to the server localhost:8080 was refused - did you specify the right host or port?
解决方案
重新进入客户端,或者重新写 ~/.kube/config
标签:kubectl,8080,遇到,更新,refused,connection,报错,k8s,server From: https://www.cnblogs.com/zuozhengjun/p/17808544.html