Rancher Server 设置
- Rancher 版本:2.4.8
Rancher使用的自签发的证书,在公网不受信任。在master节点导入kubeconfig后 执行kubectl get node 提示Unable to connect to the server: x509: certificate is valid for localhost, not $(自定义域名)。这个问题有什么办法吗
Rancher Server 设置
Rancher使用的自签发的证书,在公网不受信任。在master节点导入kubeconfig后 执行kubectl get node 提示Unable to connect to the server: x509: certificate is valid for localhost, not $(自定义域名)。这个问题有什么办法吗
在任意主机执行下面的命令,然后再试试
curl --insecure -sfL https://<server-url>/v3
如果还不行,你可以在 rancher ui 的 setting 里的 server-url
设置为公网 IP,然后 kubectl 命令好用后,再改回原来的 IP
可以了,谢谢KSD