【3】k8s集群管理系列--包应用管理器helm之chart资源打包并推送到harbor镜像仓库

一、chart资源打包

helm package  ./web-chart
# 当前目录会生成一个tgz的压缩文件

二、安装help push插件(用于推送前面打包的文件,到镜像仓库)

.1 下载help-push二进制文件

wget https://github.com/chartmuseum/helm-push/releases/download/v0.9.0/helm-push_0.9.0_linux_amd64.tar.gz

.2 安装到插件目录

tar -zxvf helm-push_0.9.0_linux_amd64.tar.gz
# 拷贝bin目录、plugin.yaml文件,到插件目录:/root/.local/share/helm/plugins/helm-push(没有则创建)
cp ./bin plugin.yaml  /root/.local/share/helm/plugins/helm-push

.3 测试插件命令

# 添加仓库
helm repo add --username admin --password Harbor12345 myrepo harbor仓库地址
helm repo update
#推送
helm push web-chart-0.1.0.tgz --username=admin --password=Harbor12345 harbor仓库地址
# 从仓库获取,安装到k8s
helm install web --version 0.1.0 myrepo/web-chart
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值