前言
Helm是Kubernetes包管理工具,类似CentOS的yum包管理工具

学习Kubernetes,了解如何通过Helm安装跟管理Kubernetes应用很有必要,下面就来介绍Helm的入门使用。
一、Helm基本管理
1.1 检查Helm版本
helm version
helm version
![]()
二、配置Helm仓库
Helm可以通过添加仓库源来使用公共的 Chart仓库
2.1 添加官方稳定Chart仓库
Helm repo add
helm repo add stable https://charts.helm.sh/stable
helm repo add stable-hub https://hub.helm.sh/stable


常见问题
#国内直接配置stable仓库报错
#报错提示一
Error: looks like "https://charts.helm.sh/stable" is not a valid chart repository or cannot be reached: Get "https://charts.helm.sh/stable/index.yaml": dial tcp: lookup charts.helm.sh: no such host
#报错提示二
Error: looks like "https://charts.helm.sh/stable" is not a valid chart repository or cannot be reached: Get "https://charts.helm.sh/stable/index.yaml": dial tcp [2606:50c0:8002::153]:443: connect: no route to host
#报错提示三
Error: looks like "https://charts.helm.sh/stable" is not a valid chart repository or cannot be reached: context deadline exceeded (Client.Timeout or context cancellation while reading body)
解决思路
由于国内网络访问的限制,建议配置私有仓库,或者国内可用的Helm仓库,参考如下2.2部分
2.2 添加国内Helm仓库
#配置国内常用的Helm仓库
helm repo add aliyun https://kubernetes.oss-cn-hangzhou.aliyuncs.com/charts
helm repo add azure http://mirror.azure.cn/kubernetes/charts
helm repo add kaiyuanshe http://mirror.kaiyuanshe.cn/kubernetes/charts
helm repo add bitnami https://charts.bitnami.com/bitnami
#arthub上ingress-nginx
helm repo add ingress-nginx https://kubernetes.github.io/ingress-nginx
2.2.1 本地Docker Desktop添加Chart仓库
aliyun

kaiyuanshe
![]()
bitnami(Vmware)

2.2.2 常用Helm Chart包
ingress-nginx(kubernetes仓库)


最低0.47元/天 解锁文章
2583

被折叠的 条评论
为什么被折叠?



