parent
669abf4de6
commit
1ebeba01a7
|
|
@ -385,8 +385,8 @@ dependencies:
|
|||
- name: redis
|
||||
repository: https://charts.bitnami.com/bitnami
|
||||
version: 17.0.7
|
||||
digest: sha256:abc123
|
||||
generated: "2024-01-01T00:00:00Z"
|
||||
digest: sha256:abc123
|
||||
generated: "2024-01-01T00:00:00Z"
|
||||
`,
|
||||
"/path/to/helmfile.d/second.yaml": `
|
||||
repositories:
|
||||
|
|
@ -404,8 +404,8 @@ dependencies:
|
|||
- name: nginx
|
||||
repository: https://charts.bitnami.com/bitnami
|
||||
version: 15.0.0
|
||||
digest: sha256:def456
|
||||
generated: "2024-01-01T00:00:00Z"
|
||||
digest: sha256:def456
|
||||
generated: "2024-01-01T00:00:00Z"
|
||||
`,
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -265,8 +265,13 @@ func getUnresolvedDependenciess(st *HelmState) (string, *UnresolvedDependencies)
|
|||
|
||||
func updateDependencies(st *HelmState, shell helmexec.DependencyUpdater, unresolved *UnresolvedDependencies, filename, wd string) (*HelmState, error) {
|
||||
lockFile := st.LockFile
|
||||
if lockFile != "" && st.basePath != "" && !filepath.IsAbs(lockFile) {
|
||||
lockFile = filepath.Join(st.basePath, lockFile)
|
||||
switch {
|
||||
case lockFile != "":
|
||||
if st.basePath != "" && !filepath.IsAbs(lockFile) {
|
||||
lockFile = filepath.Join(st.basePath, lockFile)
|
||||
}
|
||||
case st.basePath != "":
|
||||
lockFile = filepath.Join(st.basePath, filename+".lock")
|
||||
}
|
||||
|
||||
depMan := NewChartDependencyManager(filename, st.logger, lockFile)
|
||||
|
|
|
|||
|
|
@ -2548,10 +2548,10 @@ generated: 2019-05-16T15:42:45.50486+09:00
|
|||
}
|
||||
|
||||
logger := helmexec.NewLogger(io.Discard, "debug")
|
||||
basePath := "/src"
|
||||
basePath := t.TempDir()
|
||||
state := &HelmState{
|
||||
basePath: basePath,
|
||||
FilePath: "/src/helmfile.yaml",
|
||||
FilePath: filepath.Join(basePath, "helmfile.yaml"),
|
||||
ReleaseSetSpec: ReleaseSetSpec{
|
||||
Releases: []ReleaseSpec{
|
||||
{
|
||||
|
|
@ -2584,8 +2584,8 @@ generated: 2019-05-16T15:42:45.50486+09:00
|
|||
}
|
||||
|
||||
fs := testhelper.NewTestFs(map[string]string{
|
||||
"/example/Chart.yaml": `foo: FOO`,
|
||||
"/src/example/Chart.yaml": `foo: FOO`,
|
||||
"/example/Chart.yaml": `foo: FOO`,
|
||||
filepath.Join(basePath, "example/Chart.yaml"): `foo: FOO`,
|
||||
})
|
||||
fs.Cwd = basePath
|
||||
state = injectFs(state, fs)
|
||||
|
|
|
|||
Loading…
Reference in New Issue