Closed zollty closed 5 years ago
非常感谢作者,Windows 10 已成功安装。 说下过程:
[root@node1 ~]# kubectl get nodes The connection to the server 172.17.8.101:6443 was refused - did you specify the right host or port?
The connection to the server 172.17.8.101:6443 was refused - did you specify the right host or port?
检查 docker ps 发现容器都没启动,重启失败,docker logs发现error,有可能是v1.13.0的兼容性问题,换成 v1.11.0后问题解决。
您的连接不是私密连接 攻击者可能会试图从 172.17.8.101 窃取您的信息(例如:密码、通讯内容或信用卡信息)。 了解详情NET::ERR_CERT_INVALID
您的连接不是私密连接 攻击者可能会试图从 172.17.8.101 窃取您的信息(例如:密码、通讯内容或信用卡信息)。
了解详情NET::ERR_CERT_INVALID
1、生成证书
mkdir certs openssl genrsa -des3 -passout pass:x -out certs/dashboard.pass.key 2048 openssl rsa -passin pass:x -in certs/dashboard.pass.key -out certs/dashboard.key openssl req -new -key certs/dashboard.key -out certs/dashboard.csr -subj '/CN=kube-dashboard' openssl x509 -req -sha256 -days 365 -in certs/dashboard.csr -signkey certs/dashboard.key -out certs/dashboard.crt rm certs/dashboard.pass.key
2、删除原来的配置 kubectl delete -f /vagrant/addon/dashboard/kubernetes-dashboard.yaml 再执行: kubectl create secret generic kubernetes-dashboard-certs --from-file=certs -n kube-system 否则会报错: Error from server (AlreadyExists): secrets "kubernetes-dashboard-certs" already exists 然后执行: kubectl apply -f /vagrant/addon/dashboard/kubernetes-dashboard.yaml 就OK了,有warning,但不用管。
kubectl delete -f /vagrant/addon/dashboard/kubernetes-dashboard.yaml
kubectl create secret generic kubernetes-dashboard-certs --from-file=certs -n kube-system
Error from server (AlreadyExists): secrets "kubernetes-dashboard-certs" already exists
3、补充:获取token的方法 kubectl get secret -n kube-system 结果如下:
kubectl get secret -n kube-system
NAME TYPE DATA AGE admin-token-6t6kq kubernetes.io/service-account-token 3 1h coredns-token-lv855 kubernetes.io/service-account-token 3 1h default-token-mmrk7 kubernetes.io/service-account-token 3 1h kubernetes-dashboard-certs Opaque 3 9m kubernetes-dashboard-key-holder Opaque 2 1h kubernetes-dashboard-token-c26sn kubernetes.io/service-account-token 3 8m traefik-ingress-controller-token-f8tsr kubernetes.io/service-account-token 3 1h
然后执行 kubectl describe secret admin-token-6t6kq -n kube-system 就出来了。
kubectl describe secret admin-token-6t6kq -n kube-system
非常感谢作者,Windows 10 已成功安装。 说下过程:
1、第一次用 Kubernetes v1.13.0 顺利安装,但是出现如下问题
[root@node1 ~]# kubectl get nodes
The connection to the server 172.17.8.101:6443 was refused - did you specify the right host or port?
检查 docker ps 发现容器都没启动,重启失败,docker logs发现error,有可能是v1.13.0的兼容性问题,换成 v1.11.0后问题解决。
2、第二次用 Kubernetes v1.11.0 顺利安装,但是出现如下问题
您的连接不是私密连接 攻击者可能会试图从 172.17.8.101 窃取您的信息(例如:密码、通讯内容或信用卡信息)。
了解详情NET::ERR_CERT_INVALID
同 #41 ,我再补充一下解决办法
1、生成证书
2、删除原来的配置
kubectl delete -f /vagrant/addon/dashboard/kubernetes-dashboard.yaml
再执行:kubectl create secret generic kubernetes-dashboard-certs --from-file=certs -n kube-system
否则会报错:Error from server (AlreadyExists): secrets "kubernetes-dashboard-certs" already exists
然后执行: kubectl apply -f /vagrant/addon/dashboard/kubernetes-dashboard.yaml 就OK了,有warning,但不用管。3、补充:获取token的方法
kubectl get secret -n kube-system
结果如下:然后执行
kubectl describe secret admin-token-6t6kq -n kube-system
就出来了。