-
Notifications
You must be signed in to change notification settings - Fork 5.7k
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
Source path must contain a kustomization.yaml
when using kustomize.patches
#16352
Comments
I think this is actually an enhancement request, i.e. automatically create kustomization.yaml for the user if |
Good point. The bug is the wording and example in the docs. The feature request is the expected behaviour. I'll put in a PR for the former. |
Related to: argoproj#16352 Also, add an ApplicationSet example. Signed-off-by: Nicholas Morey <nicholas@morey.tech>
@morey-tech as I understand the use case is to allow users to apply last mile customization to any application (plain yaml, helm, plugin etc), correct? In this case Argo CD cannot just auto-create kustomization.yaml. E.g. app is helm-based then auto-creating kustomization.yaml would switch app to kustomize rendering and just break manifest generation. I think it is an entirely different feature. Argo CD would need to generate manifests first, then store result in e.g. spec:
...
## The field definitely should not be kustomize, because kustomize holds "inputs" for kustomize based apps.
overrides:
patches:
- target:
kind: Deployment
name: guestbook-ui
patch: |-
- op: replace
path: /spec/template/spec/containers/0/ports/0/containerPort
value: 443 |
* docs: fix kustomize patches example Related to: #16352 Also, add an ApplicationSet example. Signed-off-by: Nicholas Morey <nicholas@morey.tech> * fix: spelling Signed-off-by: Nicholas Morey <nicholas@morey.tech> --------- Signed-off-by: Nicholas Morey <nicholas@morey.tech>
* docs: fix kustomize patches example Related to: argoproj#16352 Also, add an ApplicationSet example. Signed-off-by: Nicholas Morey <nicholas@morey.tech> * fix: spelling Signed-off-by: Nicholas Morey <nicholas@morey.tech> --------- Signed-off-by: Nicholas Morey <nicholas@morey.tech> Signed-off-by: Gilad Salmon <gilad.salmon@gmail.com>
* docs: fix kustomize patches example Related to: argoproj#16352 Also, add an ApplicationSet example. Signed-off-by: Nicholas Morey <nicholas@morey.tech> * fix: spelling Signed-off-by: Nicholas Morey <nicholas@morey.tech> --------- Signed-off-by: Nicholas Morey <nicholas@morey.tech>
@alexmt My thought when contributing to the docs was the inline kustomization feature was to avoid needing any kustomize.yaml Definitely would appreciate a built in way to do last mile modifications to resources. Until then I created a quick plugin for doing kustomizations inline.
And able to consume do everything inline https://github.com/acelinkio/argocd-homelab/blob/main/manifest/knative-serving.yaml I'll try to create an equivalent one for doing last mile modification to helm charts. (Definitely do not want to leverage kustomize to use the helm binanry and do a helm release) |
* docs: fix kustomize patches example Related to: argoproj#16352 Also, add an ApplicationSet example. Signed-off-by: Nicholas Morey <nicholas@morey.tech> * fix: spelling Signed-off-by: Nicholas Morey <nicholas@morey.tech> --------- Signed-off-by: Nicholas Morey <nicholas@morey.tech>
* docs: fix kustomize patches example Related to: argoproj#16352 Also, add an ApplicationSet example. Signed-off-by: Nicholas Morey <nicholas@morey.tech> * fix: spelling Signed-off-by: Nicholas Morey <nicholas@morey.tech> --------- Signed-off-by: Nicholas Morey <nicholas@morey.tech> Signed-off-by: Kevin Lyda <kevin@lyda.ie>
* docs: fix kustomize patches example Related to: argoproj#16352 Also, add an ApplicationSet example. Signed-off-by: Nicholas Morey <nicholas@morey.tech> * fix: spelling Signed-off-by: Nicholas Morey <nicholas@morey.tech> --------- Signed-off-by: Nicholas Morey <nicholas@morey.tech>
@morey-tech is there any possibility to get this roadmaped? Thanks in advance |
I am not sure if this is expected or fully related, but we have a Edit: yes, it appears that this specific code path only wants a |
@mattrasband would you open a separate issue for that bug? And a PR if you're feeling generous. :-) |
Will do! |
I will try to get to this in the next day or so. #21914 |
Checklist:
argocd version
.Describe the bug
The docs (add in crenshaw-dev#20) state that:
However, when using the
kustomize.patches
field, the Application expects thepath
to contain akustomization.yaml
file. Without one, the sync will fail with the erroropen <path to cached source>/<path>/kustomization.yaml: no such file or directory
.To Reproduce
Deploy the Application from the example in the docs:
Expected behavior
The Application should ignore a missing
kustomization.yaml
file in thepath
whenkustomize.patches
is used. Or some equivalent (e.g. a toggle to allow missing).Screenshots
Version
Paste the output from `argocd version` here.
Logs
The text was updated successfully, but these errors were encountered: