helm search drone no results found

不知道什么原因,安裝了最新版的helm,然后安裝drone的時(shí)候,就是報(bào)找不到資源的錯(cuò)誤,可明明都helm repo update了N遍,沒辦法,最后只能選擇下載官方代碼,然后本地打包來(lái)進(jìn)行local式安裝了。附上本地helm版本:

[root@master stable]# helm version
Client: &version.Version{SemVer:"v2.9.1", GitCommit:"20adb27c7c5868466912eebdf6664e7390ebe710", GitTreeState:"clean"}
Server: &version.Version{SemVer:"v2.9.1", GitCommit:"20adb27c7c5868466912eebdf6664e7390ebe710", GitTreeState:"clean"}

廢話不多說,步驟如下:

  1. 下載官方代碼
git clone https://github.com/helm/charts
  1. 進(jìn)入stabel目錄
cd charts/stable
  1. 打包chart
helm package drone --debug

得到如下的輸出:

Successfully packaged chart and saved it to: /root/charts/stable/drone-2.0.0-rc.13.tgz
[debug] Successfully saved /root/charts/stable/drone-2.0.0-rc.13.tgz to /root/.helm/repository/local

這一步會(huì)生成類似drone-2.0.0-rc.13.tgz的包,該壓縮包被放到了當(dāng)前目錄下,并同時(shí)被保存到了helm的本地缺省倉(cāng)庫(kù)目錄中,默認(rèn)路徑在/root/.helm/repository/local/(下面會(huì)用到)

  1. 嘗試安裝
[root@master stable]# helm search drone
NAME        CHART VERSION   APP VERSION DESCRIPTION
local/drone 2.0.0-rc.13     1.0.0-rc.5  Drone is a Continuous Delivery system built on ...

這個(gè)時(shí)候search已經(jīng)能搜到了,當(dāng)然,前提肯定是你有本地的helm倉(cāng)庫(kù),可以通過如下命令查看:

[root@master stable]# helm repo list
NAME        URL
local       http://127.0.0.1:8879/charts
stable      https://kubernetes.oss-cn-hangzhou.aliyuncs.com/charts
monocular   https://helm.github.io/monocular

但是如果你此時(shí)直接helm install drone,還是會(huì)報(bào)錯(cuò)

[root@master stable]# helm install local/drone --name drone
Error: failed to download "local/drone" (hint: running `helm repo update` may help)

因?yàn)槟J(rèn)會(huì)去stable倉(cāng)庫(kù)找,這個(gè)時(shí)候就需要update默認(rèn)倉(cāng)庫(kù)

  1. 替換helm默認(rèn)倉(cāng)庫(kù)
helm repo index --url=http://127.0.0.1:8879 /root/.helm/repository/local/

后面一個(gè)參數(shù)是要替換的倉(cāng)庫(kù)的charts存放目錄,上面已經(jīng)介紹過

  1. 大功告成,安裝
helm install drone --name drone
最后編輯于
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請(qǐng)聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時(shí)請(qǐng)結(jié)合常識(shí)與多方信息審慎甄別。
平臺(tái)聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點(diǎn),簡(jiǎn)書系信息發(fā)布平臺(tái),僅提供信息存儲(chǔ)服務(wù)。

相關(guān)閱讀更多精彩內(nèi)容

友情鏈接更多精彩內(nèi)容