Merge pull request #371 from toVersus/fix/oci-pull-bug

fix: add missing untar flag to pull chart from oci registry
This commit is contained in:
yxxhero
2022-09-18 19:36:39 +08:00
committed by GitHub
6 changed files with 111 additions and 3 deletions
+1 -1
View File
@@ -466,7 +466,7 @@ func (helm *execer) ChartPull(chart string, path string, flags ...string) error
// in the 3.7.0 version, the chart pull has been replaced with helm pull
// https://github.com/helm/helm/releases/tag/v3.7.0
ociChartURL, ociChartTag := resolveOciChart(chart)
helmArgs = []string{"pull", ociChartURL, "--version", ociChartTag, "--destination", path}
helmArgs = []string{"pull", ociChartURL, "--version", ociChartTag, "--destination", path, "--untar"}
} else {
helmArgs = []string{"chart", "pull", chart}
}
+1 -1
View File
@@ -733,7 +733,7 @@ exec: helm --kube-context dev chart pull chart --untar --untardir /tmp/dir
chartPath: "path1",
chartFlags: []string{"--untardir", "/tmp/dir"},
listResult: `Pulling repo/helm-charts:0.14.0
exec: helm --kube-context dev pull oci://repo/helm-charts --version 0.14.0 --destination path1 --untardir /tmp/dir
exec: helm --kube-context dev pull oci://repo/helm-charts --version 0.14.0 --destination path1 --untar --untardir /tmp/dir
`,
},
}