【问题标题】:JFrog Helm repository always returns 404JFrog Helm 存储库总是返回 404
【发布时间】:2021-10-14 06:43:23
【问题描述】:

我的 JFrog 帐户中有 3 个 helm 存储库:

  • helm-local - 用于存储私有 helm 图表
  • helm-remote - 用于代理公共图表
  • helm - 虚拟机,将两者结合在一起

我像这样配置我的 helm 客户端:helm repo add %reponame% https://%name%.jfrog.io/artifactory/helm --username %username% --password %password%,因为它在 https://www.jfrog.com/confluence/display/RTF6X/Helm+Chart+Repositories 中描述。 然后我做helm repo update

但是当我尝试执行helm pull %reponame%/%chartname% 时,它返回 404

Error: failed to fetch https://%name%.jfrog.io/helm-local/%chartname%-%chartversion%.tgz : 404 Not Found
helm.go:88: [debug] failed to fetch https://%name%.jfrog.io/helm-local/%chartname%-%chartversion%.tgz : 404 Not Found
helm.sh/helm/v3/pkg/getter.(*HTTPGetter).get
        helm.sh/helm/v3/pkg/getter/httpgetter.go:90
helm.sh/helm/v3/pkg/getter.(*HTTPGetter).Get
        helm.sh/helm/v3/pkg/getter/httpgetter.go:42
helm.sh/helm/v3/pkg/downloader.(*ChartDownloader).DownloadTo
        helm.sh/helm/v3/pkg/downloader/chart_downloader.go:99
helm.sh/helm/v3/pkg/action.(*Pull).Run
        helm.sh/helm/v3/pkg/action/pull.go:129
main.newPullCmd.func2
        helm.sh/helm/v3/cmd/helm/pull.go:75
github.com/spf13/cobra.(*Command).execute
        github.com/spf13/cobra@v1.1.3/command.go:852
github.com/spf13/cobra.(*Command).ExecuteC
        github.com/spf13/cobra@v1.1.3/command.go:960
github.com/spf13/cobra.(*Command).Execute
        github.com/spf13/cobra@v1.1.3/command.go:897
main.main
        helm.sh/helm/v3/cmd/helm/helm.go:87
runtime.main
        runtime/proc.go:225
runtime.goexit
        runtime/asm_amd64.s:1371

似乎正在获取索引,并获取最新版本的图表,但无法获取正确的下载 URL。 我做错了什么?

【问题讨论】:

  • 我看你是想直接从helm-local拉取,可以用helm virtual试试拉取吗?另外,能不能在虚拟repo上做zap缓存,在本地repo上重新计算索引,测试pull?
  • @MuhammedKashif 我正在从添加到 helm 的 repo 中提取,它是 /helm - 已经是虚拟的。所以我做helm repo add ABC https://.../helm,在helm pull ABC/chart 上它被解析为https://.../helm-local/chart-version.tgz。我会尝试重新计算索引,如果有帮助,请告诉您,谢谢!
  • 谢谢@MuhammedKashif,索引重建有帮助,在新索引中链接变得正确!
  • 很高兴知道它有效 :)
  • @MuhammedKashif 你不想建议一个答案,以便我接受吗?

标签: kubernetes-helm jfrog jfrog-container-registry


【解决方案1】:

我看到你正在尝试直接从 helm-local 拉取,你可以使用 helm virtual 并尝试拉取吗?另外,能不能在虚拟repo上做zap缓存,在本地repo上重新计算索引,测试一下pull?

【讨论】:

  • 我实际上使用了 helm virtual,但是下载的索引包含对 helm-local 的引用。我还尝试重新计算 JFrog UI 中的索引,这很有帮助 - 索引中的链接变得正确!谢谢!
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 2021-08-05
  • 2015-07-31
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2016-02-04
  • 2014-05-29
相关资源
最近更新 更多