helmfile/pkg/app
Yusuke Kuoka 8e50dbc46d Fix helmfile deps not to remove entries for charts that are being chartified
When chartify is involved due to the use of `forceNamespace`, `strategicMergePatches`, `jsonPatches`, and so on, We had been internally mutating the Release.Chart with the path to the local temporary directory that contains the modified version of the chart.

This resulted in us unintentionally making `helmfile deps` to remove entries for the chart being modified out of helmfile.lock file, which resulted in issues like #2110.

To be clear, although the original issue is reported to occur for `strategicMergePatches`, I believe that it occurered also for any remote charts using `jsonPatches` and `forceNamespace` too.

I also believe this has been the issue since our introduction of chartify (maybe a year or so ago??), and I guess why it took so much time to be found and reported is that not so many people with chartify in combination with `helmfile deps` 🤔

Lastly, this changes chart names surfaced in the various log output from Helmfile, from temporary chart paths to the chart name/path declared in the helmfile.yaml. I think this is generally a good change, no fear of being a breaking change. But if anyone has any concern about that, please feel free to comment/report/etc.

Ref https://github.com/roboll/helmfile/issues/2110

Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com>
2022-04-06 02:12:08 +00:00
..
testdata add unit for formatters.go 2022-04-03 17:31:59 +08:00
version feat: Persist Helmfile version in helmfile.lock for version compatibility check (#1016) 2019-12-11 09:19:18 +09:00
app.go remove ioutil usage in all project 2022-04-03 15:53:19 +08:00
app_apply_nokubectx_test.go Add support for transitive dependencies. (#1983) 2021-10-20 17:55:08 +09:00
app_apply_test.go Stop panic when deduplicating releases (#2067) 2022-03-10 18:57:58 +09:00
app_sync_test.go Add support for transitive dependencies. (#1983) 2021-10-20 17:55:08 +09:00
app_test.go mv captureStdout as public func 2022-04-03 22:24:38 +08:00
ask.go feat: helmfile as a go library (#639) 2019-06-04 09:12:00 +09:00
config.go feat: Add --suppress option for diff and apply commands (#2077) 2022-02-03 08:46:39 +09:00
constants.go feat: "bases" for easier layerina 2019-05-13 21:48:00 +09:00
constants_test.go Bump golang to v1.14.2 (#1132) 2020-04-21 09:06:29 +09:00
context.go Fix repo sync to work on repos duplicated between helm v2 and v3 (#1816) 2021-04-30 09:27:23 +09:00
desired_state_file_loader.go feat: Add go-getter support to load base helmfiles (#1998) 2021-12-21 09:16:24 +09:00
destroy_nokubectx_test.go Add support for transitive dependencies. (#1983) 2021-10-20 17:55:08 +09:00
destroy_test.go Add support for transitive dependencies. (#1983) 2021-10-20 17:55:08 +09:00
diff_nokubectx_test.go Do fail on a possible typo in `needs` entries (#2026) 2021-12-18 17:44:55 +09:00
diff_test.go feat: Add --suppress option for diff and apply commands (#2077) 2022-02-03 08:46:39 +09:00
errors.go feat: Opt-out dep-builds and repo-updates (#463) 2019-02-04 12:07:25 +09:00
formatters.go Correct enabled property in helmfile list (#1921) 2022-01-10 17:24:07 +09:00
formatters_test.go mv captureStdout as public func 2022-04-03 22:24:38 +08:00
load_opts.go Fix and enhancement to repository update (#1383) 2020-07-28 10:17:43 +09:00
load_opts_test.go add unittest for load_opts.go 2022-04-04 17:20:54 +08:00
mocks_test.go Fix various golangci-lint errors (#2059) 2022-02-12 20:28:08 +09:00
run.go Fix helmfile deps not to remove entries for charts that are being chartified 2022-04-06 02:12:08 +00:00
snapshot_test.go remove ioutil usage in all project 2022-04-03 15:53:19 +08:00
two_pass_renderer.go Add .StateValues as alias of .Values in EnvironmentTemplateData (#2056) 2022-03-31 10:57:33 +09:00
two_pass_renderer_test.go Fix various golangci-lint errors (#2059) 2022-02-12 20:28:08 +09:00