安装:
国外官方地址:https://github.com/helm/helm/releases
国内镜像地址:
https://mirrors.huaweicloud.com/helm/
下载
wget https://mirrors.huaweicloud.com/helm/v3.15.4/helm-v3.15.4-linux-amd64.tar.gz
tar -xvf helm-v3.15.4-linux-amd64.tar.gz
cp /usr/bin/
sudo cp -a linux-amd64/helm /usr/bin
helm version
helm version
version.BuildInfo{Version:"v3.15.4", GitCommit:"fa9efb07d9d8debbb4306d72af76a383895aa8c4", GitTreeState:"clean", GoVersion:"go1.22.6"}
add repo
# 查看当前配置的仓库地址
helm repo list
# 删除默认仓库,默认在国外pull很慢
helm repo remove stable
# 添加几个常用的仓库,可自定义名字
helm repo add https://kubernetes.oss-cn-hangzhou.aliyuncs.com/charts
helm repo add kaiyuanshe http://mirror.kaiyuanshe.cn/kubernetes/charts
helm repo add stable http://mirror.azure.cn/kubernetes/charts
helm repo add dandydev https://dandydeveloper.github.io/charts
helm repo add bitnami https://charts.bitnami.com/bitnami
# 搜索chart
helm search repo redis
# 拉取chart包到本地
helm pull bitnami/redis-cluster --version 8.1.2
# 安装redis-ha集群,取名redis-ha,需要指定持存储类
helm install redis-cluster bitnami/redis-cluster --set global.storageClass=nfs,global.redis.password=xiagao --version 8.1.2
# 卸载
helm uninstall redis-cluster