-
Notifications
You must be signed in to change notification settings - Fork 2.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
helmCharts valuesFile does not work when file path contains filepath up (cd ..) #5494
Comments
I think maybe this is a security check that prevents kustomizations from reading files outside their own directory root. Could you try /area helm |
@koba1t: The label(s) In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/triage needs-information |
Since I just had the same issue: Yep, that helps! |
The Kubernetes project currently lacks enough contributors to adequately respond to all issues. This bot triages un-triaged issues according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle stale |
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues. This bot triages un-triaged issues according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle rotten |
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs. This bot triages issues according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /close not-planned |
@k8s-triage-robot: Closing this issue, marking it as "Not Planned". In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
Could this be re-opened? I think this could be reconsidered, if you wouldn't mind. I am struggling to see if this is currently restricted as a recommendation in general, if using Because, to me, My example would be the following use. I use a helm chart
What I want to do is to have a Then I would have some Resource descriptionsIn dev you would have one version inflated, with experimental support # overlays/dev/kustomize.yaml
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: dev
resources:
- ../../base
patches:
- ...
helmGlobals:
chartHome: ../../charts/
helmCharts:
- name: ruby-base
valuesInline:
resourceName: dev-client-1
experimental_assets: true
Multiple versions inflated in test # overlays/test/kustomize.yaml
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: test
resources:
- ../../base
patches:
- ...
helmGlobals:
chartHome: ../../charts/
helmCharts:
- name: ruby-base
valuesInline:
resourceName: test-client-1
experimental_assets: true
- name: ruby-base
valuesInline:
resourceName: test-client-1
experimental_assets: false
And finally, in prod multiple for each client, without any experimental/beta features # overlays/production/kustomize.yaml
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: production
resources:
- ../../base
patches:
- ...
helmGlobals:
chartHome: ../../charts/
helmCharts:
- name: ruby-base
valuesInline:
resourceName: client-1
experimental_assets: false
- name: ruby-base
valuesInline:
resourceName: client-2
experimental_assets: false Of course, |
@alexrecuenco kustomize/plugin/builtin/helmchartinflationgenerator/HelmChartInflationGenerator.go Lines 98 to 104 in cc9dd34
kustomize/plugin/builtin/helmchartinflationgenerator/HelmChartInflationGenerator.go Line 110 in cc9dd34
|
What happened?
File Structure
├── k8s/
| ├── base/
| | ├── helm/
| | | ├── gitops/
| | | | ├── argo-cd/ (Helm Chart Pulled)
| | | | ├── base-argo-cd-values.yaml
| | | | ├── kustomization.yaml
| ├── dev/
| | ├── helm/
| | | ├── gitops/
| | | | ├── dev-argo-cd-values.yaml
| | | | ├── kustomization.yaml
base-argo-cd-values.yaml
Currently Empty
k8s/base/helm/gitops/kustomization.yaml
k8s/dev/helm/gitops/kustomization.yaml
valuesFile
takes a file path, it works for filePaths going down, but does not work when file path contains..
to go up a directory.Run:
kustomize build k8s/dev/helm/gitops --enable-helm
Error:
1)
I looked at this issue and it doesn't seem fixed: #5163
Per docs:
https://kubectl.docs.kubernetes.io/references/kustomize/builtins/#_helmchartinflationgenerator_
Even though I don't specify the repo key. Its still trying to pull repo instead of looking at chartHome
Having
base-argo-cd-values.yaml
in a file location without..
works. For example in the same directory or nested directoryWhat did you expect to happen?
kustomize builds successfully.
How can we reproduce it (as minimally and precisely as possible)?
See file structure and yaml above.
Expected output
Actual output
Kustomize version
v5.3.0
Operating system
MacOS
The text was updated successfully, but these errors were encountered: