首页 > Web开发 > 详细

Kubernetes 认证

时间:2017-01-11 10:01:52      阅读:228      评论:0      收藏:0      [点我收藏+]

openssl genrsa -out ca.key 2048
openssl req -x509 -new -nodes -key ca.key -subj "/CN=cluster.local" -days 5000 -out ca.crt
openssl genrsa -out server.key 2048
openssl req -new -key server.key -subj "/CN=kubernetes-master" -out server.csr
openssl x509 -req -in server.csr -CA ca.crt -CAkey ca.key -CAcreateserial -out server.crt -days 5000

 

 

--service-account-private-key-file provided to the controller manager is used to sign service account tokens. The corresponding public key must be provided to the api server with --service-account-key-file, which uses it to verify tokens.

As a convenience, you can provide a private key to both, and the public key portion of it will be used by the api server to verify token signatures.

As a further convenience, the api server‘s private key for it‘s serving certificate is used to verify service account tokens if you don‘t specify --service-account-key-file

--tls-cert-file and --tls-private-key-file are used to provide the serving cert and key to the api server. If you don‘t specify these, the api server will make a self-signed cert/key-pair and store it at apiserver.crt/apiserver.key

 

https://github.com/kubernetes/kubernetes/issues/22351#event-913006676

Kubernetes 认证

原文:http://www.cnblogs.com/zhangeamon/p/6272445.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!