mirror of
https://github.com/kubernetes-sigs/kustomize.git
synced 2026-06-13 01:50:55 +00:00
kustomize: Add support for OCI based helm repos (#5167)
* kustomize: Add support for OCI based helm repos Signed-off-by: Jan-Otto Kröpke <joe@cloudeteer.de> * Update api/internal/builtins/HelmChartInflationGenerator.go * Update plugin/builtin/helmchartinflationgenerator/HelmChartInflationGenerator.go * go fmt Signed-off-by: Jan-Otto Kröpke <joe@cloudeteer.de> * s/expectedHelmExternalDns/expectedHelmExternalDNS Signed-off-by: Jan-Otto Kröpke <joe@cloudeteer.de> * commit Signed-off-by: Jan-Otto Kröpke <joe@cloudeteer.de> * commit with content Signed-off-by: Jan-Otto Kröpke <joe@cloudeteer.de> * Apply suggestions from maintainer * go work sync * added test --------- Signed-off-by: Jan-Otto Kröpke <joe@cloudeteer.de>
This commit is contained in:
@@ -281,8 +281,18 @@ func (p *HelmChartInflationGeneratorPlugin) pullCommand() []string {
|
||||
"pull",
|
||||
"--untar",
|
||||
"--untardir", p.absChartHome(),
|
||||
"--repo", p.Repo,
|
||||
p.Name}
|
||||
}
|
||||
|
||||
switch {
|
||||
case strings.HasPrefix(p.Repo, "oci://"):
|
||||
args = append(args, strings.TrimSuffix(p.Repo, "/")+"/"+p.Name)
|
||||
case p.Repo != "":
|
||||
args = append(args, "--repo", p.Repo)
|
||||
fallthrough
|
||||
default:
|
||||
args = append(args, p.Name)
|
||||
}
|
||||
|
||||
if p.Version != "" {
|
||||
args = append(args, "--version", p.Version)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user