首页 > 其他 > 详细

k8s安装

时间:2019-12-18 00:52:41      阅读:165      评论:0      收藏:0      [点我收藏+]

kubeadm init --kubernetes-version=1.17.0 --apiserver-advertise-address=192.168.122.55 --image-repository registry.aliyuncs.com/google_containers --service-cidr=10.1.0.0/16 --pod-network-cidr=10.244.0.0/16

 

 

 

 

 

 

 

https://www.kubernetes.org.cn/5462.html

 


To start using your cluster, you need to run the following as a regular user:

mkdir -p $HOME/.kube
sudo cp -i /etc/kubernetes/admin.conf $HOME/.kube/config
sudo chown $(id -u):$(id -g) $HOME/.kube/config

You should now deploy a pod network to the cluster.
Run "kubectl apply -f [podnetwork].yaml" with one of the options listed at:
https://kubernetes.io/docs/concepts/cluster-administration/addons/

Then you can join any number of worker nodes by running the following on each as root:

kubeadm join 192.168.122.55:6443 --token fuu0zz.1oj3o8zbsf0eyj1x \
--discovery-token-ca-cert-hash sha256:26f14aed87dffb4ac88f8166b55386dbb36fcb8a381431205110008aeda22f6b

https://stackoverflow.com/questions/58971938/unable-to-recognize-kube-flannel-yml-no-matches-for-kind-daemonset-in-versi
It seems you‘re using k8s version 1.16 and daemonset API group change to apps/v1
Update the link to this: https://raw.githubusercontent.com/coreos/flannel/master/Documentation/kube-flannel.yml
And also there is an issue about this out there: https://github.com/kubernetes/website/issues/16441
shareimprove this answer
answered Nov 21 at 9:57
Alireza Davoodi
63055 silver badges1818 bronze badges
resolved master pending node issue but still node not able to join – Ashish Karpe Nov 21 at 10:05
1
Please check the flannel daemonset, Is it running on all nodes? – Alireza Davoodi Nov 21 at 10:07
how to do that? – Ashish Karpe Nov 21 at 10:09
1
kubectl -n kube-system get daemonset kube-flannel-ds-amd64 -o wide Should run on all nodes. – Alireza Davoodi Nov 21 at 10:11
1
You don‘t need to add explicitly a pod to the node because already you‘re using daemonset so that object apply a pod to all of the cluster nodes. – Alireza Davoodi Nov 21 at 10:16

k8s安装

原文:https://www.cnblogs.com/dablyo/p/12057644.html

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