ubuntu安装kubeadm、kubelet、kubectl
// 安装所需要的包sudo apt-get updatesudo apt-get install -y apt-transport-https ca-certificates curl// 下载 Google Cloud 公开签名秘钥:sudo curl -fsSLo /usr/share/keyrings/kubernetes-archive-keyring.gpg https://packa
·
// 安装所需要的包
sudo apt update
sudo apt install -y apt-transport-https ca-certificates curl
// 下载 Google Cloud 公开签名秘钥(阿里云镜像):
curl -fsSL https://mirrors.aliyun.com/kubernetes/apt/doc/apt-key.gpg | sudo gpg --dearmor -o /etc/apt/keyrings/kubernetes-archive-keyring.gpg
// 添加 Kubernetes apt 仓库(阿里云镜像):
echo "deb [signed-by=/etc/apt/keyrings/kubernetes-archive-keyring.gpg] https://mirrors.aliyun.com/kubernetes/apt/ kubernetes-xenial main" | sudo tee /etc/apt/sources.list.d/kubernetes.list
安装 kubelet、kubeadm 和 kubectl,并锁定其版本:
sudo apt update
sudo apt install -y kubelet kubeadm kubectl
sudo apt-mark hold kubelet kubeadm kubectl
官方文档:https://kubernetes.io/zh/docs/setup/production-environment/tools/kubeadm/install-kubeadm/
更多推荐
已为社区贡献1条内容
所有评论(0)