阿里雲 kubernetes yum 倉庫鏡像

安裝kubernetes的時候,須要安裝kubelet, kubeadm等包,但k8s官網給的yum源是packages.cloud.google.com,國內訪問不了,此時咱們可使用阿里雲的yum倉庫鏡像。python

阿里雲上沒有附Help說明鏈接,簡單摸索了下,以下設置可用(centos)。注意不要開啓check。centos

1
2
3
4
5
6
7
8
9
10
cat <<EOF >  / etc / yum.repos.d / kubernetes.repo
[kubernetes]
name = Kubernetes
baseurl = http: / / mirrors.aliyun.com / kubernetes / yum / repos / kubernetes - el7 - x86_64
enabled = 1
gpgcheck = 0
repo_gpgcheck = 0
gpgkey = http: / / mirrors.aliyun.com / kubernetes / yum / doc / yum - key.gpg
        http: / / mirrors.aliyun.com / kubernetes / yum / doc / rpm - package - key.gpg
EOF
相關文章
相關標籤/搜索