我正在尝试连接到由kubeadm在AWS lightsail实例(Master &2 worker节点)上部署的kubernetes集群。我将.kube/config文件复制到本地计算机,并将server: https://172.26.2.101:6443替换为server: https://<public_ip_address>:6443Unable to connect to the server: x509: certificate is valid for 10.96.0.1,
通过安装Istio,您可以知道它会创建一个带有publicIP的kubernetes负载均衡器,并使用公网IP作为istio-ingress-gateway loadbalancer服务的外部IP。由于该IP不是静态的,所以我在Azure中创建了一个静态的公网IP,该公网IP和AKS在同一个ResourceGroup中,所以我找到了如下的资源组名称:
$ az aks show --resource-grouphttps:/