helm-v2.14.1 安装

  sre

清理老helm

helm reset --force
kubectl delete serviceaccount  tiller --namespace kube-system
kubectl delete clusterrolebinding tiller-cluster-rule  
kubectl delete deployment tiller-deploy --namespace kube-system

helm客户端安装

wget https://get.helm.sh/helm-v2.14.1-linux-amd64.tar.gz
tar zxvf helm-v2.14.1-linux-amd64.tar.gz
mv linux-amd64/helm /usr/local/bin/helm

rbac

kubectl create serviceaccount --namespace kube-system tiller
kubectl create clusterrolebinding tiller-cluster-rule --clusterrole=cluster-admin --serviceaccount=kube-system:tiller

helm init

helm init --upgrade -i registry.cn-hangzhou.aliyuncs.com/google_containers/tiller:v2.14.1 --stable-repo-url https://kubernetes.oss-cn-hangzhou.aliyuncs.com/charts --history-max 300

查看:

helm version
Client: &version.Version{SemVer:"v2.14.1", GitCommit:"5270352a09c7e8b6e8c9593002a73535276507c0", GitTreeState:"clean"}
Server: &version.Version{SemVer:"v2.14.1", GitCommit:"5270352a09c7e8b6e8c9593002a73535276507c0", GitTreeState:"clean"}

kubectl get deployment tiller-deploy -n kube-system

测试:

helm install stable/nginx-ingress --name nginx-ingress
helm ls
helm delete nginx-ingress

charts源操作

查看:

[root@master01 ~]# helm repo list
NAME    URL                                             
stable  https://kubernetes-charts.storage.googleapis.com
local   http://127.0.0.1:8879/charts  

删除:

[root@master01 ~]# helm repo remove stable local
"stable" has been removed from your repositories
"local" has been removed from your repositories

增加:

[root@master01 ~]# helm repo add stable https://kubernetes.oss-cn-hangzhou.aliyuncs.com/charts
"stable" has been added to your repositories
[root@master01 ~]# helm repo list
NAME    URL                                                   
stable  https://kubernetes.oss-cn-hangzhou.aliyuncs.com/charts


搜索:

[root@master01 ~]# helm search mysql
NAME                            CHART VERSION   APP VERSION DESCRIPTION                                                 
stable/mysql                    0.3.5                       Fast, reliable, scalable, and easy to use open-source rel...
stable/percona                  0.3.0                       free, fully compatible, enhanced, open source drop-in rep...
stable/percona-xtradb-cluster   0.0.2           5.7.19      free, fully compatible, enhanced, open source drop-in rep...
stable/gcloud-sqlproxy          0.2.3                       Google Cloud SQL Proxy                                      
stable/mariadb                  2.1.6           10.1.31     Fast, reliable, scalable, and easy to use open-source rel...

LEAVE A COMMENT

Captcha Code