diff --git a/README.md b/README.md new file mode 100644 index 0000000..3be7c0a --- /dev/null +++ b/README.md @@ -0,0 +1,29 @@ +Related Github issue: https://github.com/helmfile/helmfile/issues/743 + +When using a kustomization, `helmfile template` fails with `Error: unknown flag: --load_restrictor]` +Downgrading `kustomize` to i.e. `4.5.6` fixed it. + +Steps to reproduce: + +* Install Kustomize >= 5 + +Then: + + https://github.com/hinricht/helmfile-kustomize5.git + cd helmfile-kustomize5 + helmfile template + +With Kustomize>=5 this error will show: + +``` +$ helmfile template +in ./helmfile.yaml: [exit status 1 + +COMMAND: + kustomize -o /tmp/chartify559297089/test/monitoring/test/templates/kustomized.yaml build --load_restrictor=none --enable_alpha_plugins /tmp/chartify559297089/test/monitoring/test + +OUTPUT: + Error: unknown flag: --load_restrictor] +``` + +With Kustomize <5 `helmfile template` works as expected. diff --git a/helmfile.yaml b/helmfile.yaml new file mode 100644 index 0000000..74f323f --- /dev/null +++ b/helmfile.yaml @@ -0,0 +1,7 @@ +helmDefaults: + kubeContext: "test" + +releases: + - name: test + namespace: monitoring + chart: ./test diff --git a/test/kustomization.yaml b/test/kustomization.yaml new file mode 100644 index 0000000..7096802 --- /dev/null +++ b/test/kustomization.yaml @@ -0,0 +1,2 @@ +resources: +- test.yaml diff --git a/test/test.yaml b/test/test.yaml new file mode 100644 index 0000000..d325236 --- /dev/null +++ b/test/test.yaml @@ -0,0 +1,4 @@ +apiVersion: v1 +kind: Namespace +metadata: + name: monitoring