K8S 证书
source link: https://linuxsuren.github.io/blog/devops/k8s/cert/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
根证书公钥(ca.pem)与私钥(ca-key.pem)
API Server 公钥和私钥
集群管理员公钥和私钥
从节点公钥和私钥
openssl genrsa -out ca-key.pem 2048
openssl req -x509 -new -nodes -key ca-key.pem -days 10000 -out ca.pem -subj "/CN=kube-ca"
API Server 证书
创建 openssl.cnf
[req]
req_extensions = v3_req
distinguished_name = req_distinguished_name
[req_distinguished_name]
[ v3_req ]
basicConstraints = CA:FALSE
keyUsage = nonRepudiation, digitalSignature, keyEncipherment
subjectAltName = @alt_names
[alt_names]
DNS.1 = kubernetes
DNS.2 = kubernetes.default
DNS.3 = kubernetes.default.svc
DNS.4 = kubernetes.default.svc.cluster.local
IP.1 = ${K8S_SERVICE_IP}
IP.2 = ${MASTER_IPV4}
openssl genrsa -out apiserver-key.pem 2048
openssl req -new -key apiserver-key.pem -out apiserver.csr -subj "/CN=kube-apiserver" -config openssl.cnf
openssl x509 -req -in apiserver.csr -CA ca.pem -CAkey ca-key.pem -CAcreateserial -out apiserver.pem -days 365 -extensions v3_req -extfile openssl.cnf
一般生成的根证书(ca-key.pem, ca.pem)与 apiserver 证书(apiserver-key.pem,apiserver.pem)放置在 Master 节点的 /etc/kubernetes/ssl/
路径下
Recommend
-
87
solidot新版网站常见问题,请点击这里查看。 提交文章 ...
-
114
白帽子袁炜在乌云网提交世纪佳缘漏洞被抓一事,你应该有所耳闻吧?这在当时引起了不小的轰动,白帽子与企业如何相处一度成为一大热门话题。就在近日,一则白帽子遭大疆威胁的事件,再一次将白帽子与企业信息安全推上了风口浪尖。下面我们一起来看看事情的经过。1....
-
88
全球工单系统 - @twoyuan - https://i.imgur.com/aNZ3JoJ.png
-
66
https CA自签名证书,并给Webserver颁发证书
-
66
马上又要到了情人节和婚礼筹备季,随着近些年物质生活越来越丰富,钻戒似乎已经成为了结婚的必备单品。一颗晶莹剔透的钻石,不仅是无数姑娘们心之向往的小梦想,也是同甘共苦后两人情感的见证,更使整个婚礼增添了一分仪式感。
-
98
绕过安卓SSL验证证书的四种方式
-
64
HTTPS安全证书访问连接知识讲解01:网络安全涉及的问题: ①. 网络安全问题-数据机密性问题 传输的数据可能会被第三方随时都能看到 ②....
-
122
NGINX - @abccccabc - 你们的 https 证书是在哪里买的??那种证书好些,听说赛门铁克的证书 chrome 认为不安全了,我想让我的网址在 chrome 上出现绿锁。
-
60
-
10
cer-manager 是一个证书管理器,可以自动颁发和更新证书来保护ingress 首先下载yaml文件 wget https://github.com/cert-mana...
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK