【问题标题】:Helm /.helm/repository/local/index.yaml file is emptyHelm /.helm/repository/local/index.yaml 文件为空
【发布时间】:2020-02-13 21:01:21
【问题描述】:

我有一个私人 git 存储库来存储公司掌舵图。这个 git repo 有 .tgz 和 index.yaml 文件。

我正在尝试使用 helm serve . 在本地测试/重新运行现有图表

我现在遇到的问题是,helm serve 不服务于本地私人掌舵图。

~/.helm/repository/local下的index.yaml文件为空。

cd ~/.helm/repository/local
 $ cat index.yaml             
apiVersion: v1
entries: {}
generated: "2019-09-29T10:38:13.526444+01:00"

另外helm search local/ 无法找到我正在查找的图表。

 $ helm search local/ 
 No results found
$ helm repo list 
NAME    URL                                         
stable  https://kubernetes-charts.storage.googleapis.com
local   http://127.0.0.1:8879 

我期待的是index.yaml~/.helm/repository/local 下应该有私人图表列表。 helm search local/ 会返回我正在寻找的图表。

我还注意到helm serve 命令将index.yaml 文件重置为空,而不是加载私有图表。

【问题讨论】:

    标签: kubernetes-helm


    【解决方案1】:

    如果您想从非默认目录提供图表,请使用helm serve --repo-path <path>

    这个github issue 也可能是相关的。根据它,您必须为本地服务添加一个单独的存储库,例如helm repo add test http://127.0.0.1:8879/

    【讨论】:

      【解决方案2】:

      我可以在运行本地图表存储服务器后解决这个问题,该服务器指向带有图表的本地文件夹。 helm serve --repo-path ~/.helm/repository/local。这让我可以使用命令helm install local/{chartName} 运行本地图表。 index.yaml 在本地服务器运行后重新生成。

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 2020-04-15
        • 1970-01-01
        • 2022-11-11
        • 2020-01-12
        • 1970-01-01
        • 2019-04-18
        • 1970-01-01
        • 2021-12-04
        相关资源
        最近更新 更多