首页 > 其他 > 详细

K8S集群搭建案例

时间:2019-08-21 01:27:07      阅读:105      评论:0      收藏:0      [点我收藏+]

参考文档:
https://yq.aliyun.com/articles/419570?spm=5176.10695662.1996646101.searchclickresult.547174c9nMJ4R6

 

在Master节点上需要安装的服务:

docker | etcd | flannel | kube-apiserver | kube-schedulerkube-controller-manager ]

在Slave(Node)节点上需要安装的服务:
[ dockerflannel | kubelet | kube-proxy ]

 

1.解决kubectl get pods时 No resources found的问题:

1、vi /etc/kubernetes/apiserver
2、找到
"KUBE_ADMISSION_CONTROL="--admission_control=NamespaceLifecycle,NamespaceExists,LimitRanger,SecurityContextDeny,ServiceAccount,ResourceQuota",去掉ServiceAccount,保存退出。
3、systemctl restart kube-apiserver
 

2.解决在pul镜像image的时候没有凭据,没有redhat-ca.crt文件的问题:

[具体报错:Trying to pull repository registry.access.redhat.com/rhel7/pod-infrastructure ...  open /etc/docker/certs.d/registry.access.redhat.com/redhat-ca.crt: no such file or directory]

wget http://mirror.centos.org/centos/7/os/x86_64/Packages/python-rhsm-certificates-1.19.10-1.el7_4.x86_64.rpm
rpm2cpio python-rhsm-certificates-1.19.10-1.el7_4.x86_64.rpm | cpio -iv --to-stdout ./etc/rhsm/ca/redhat-uep.pem | tee /etc/rhsm/ca/redhat-uep.pem    
//前两个命令会生成/etc/rhsm/ca/redhat-uep.pem文件.     
docker pull registry.access.redhat.com/rhel7/pod-infrastructure:latest

  

 

K8S集群搭建案例

原文:https://www.cnblogs.com/sdrbg/p/11386477.html

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