Skip to content
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

Add new YamlOutputType to generate a tree of charts #2160

Open
2 tasks
baptman21 opened this issue Jul 4, 2024 · 1 comment
Open
2 tasks

Add new YamlOutputType to generate a tree of charts #2160

baptman21 opened this issue Jul 4, 2024 · 1 comment
Labels
@component/cdk8s-core Issue related to cdk8s-core effort/medium 1 week tops feature-request New/Enhanced functionality wanted priority/p2 Dependent on community feedback. PR's are welcome :)

Comments

@baptman21
Copy link

Description of the feature or enhancement:

Add a new YamlOutputType to generate the charts in a tree of folders for subcharts:

output-dir
| chart-a/
|   | subchart-a1/
|   | subchart-a2/
| chart-b/
|   | subchart-b1/
|   | subchart-b2/

Instead of the current

output-dir/
| XXXX-chart-a
| XXXX-chart-b
| XXXX-subchart-a1
| XXXX-subchart-a2
| XXXX-subchart-b1
| XXXX-subchart-b2

Use Case:

Currently, the only types of generations in yaml are:

  • One file
  • One file per resource
  • One folder per chart and One file per resource

The problem I have been experiencing is that when you have a big infrastructure with a lot of subcharts, the output is more difficult to read and review, since you have many folders in the same output folder.

Proposed Solution:

Had a case in app.ts to generate the folders using the dependency graph.

Other:

I think they are alternatives to this feature. For example, I suppose that you can use multiple Apps in your code, using an App of Apps patterns if you want to split the output. Did anyone ever use this pattern ? My main question on this is, would it work well to use multiple Apps in the same bit of code, and call synth() on all of them.

  • 👋 I may be able to implement this feature request
  • ⚠️ This feature might incur a breaking change

This is a 🚀 Feature Request

@baptman21 baptman21 added feature-request New/Enhanced functionality wanted needs-triage Priority and effort undetermined yet labels Jul 4, 2024
@shinebayar-g
Copy link

shinebayar-g commented Jul 15, 2024

I'm currently renaming output directories in my cdk8s app.ts after app.synth() is called. If I move directories outside of the cdk8s --output dir parameter, cdk8s says No manifests synthesized. But if I move directories only inside that parameter, cdk8s correctly recognizes the moved directories. I'm relying on this behavior for the moment until cdk8s supports more flexible output dir mechanism.

I suppose that you can use multiple Apps in your code

I think I tried that, don't remember if it worked successfully.

@iliapolo iliapolo added priority/p2 Dependent on community feedback. PR's are welcome :) effort/medium 1 week tops and removed needs-triage Priority and effort undetermined yet labels Jul 28, 2024
@iliapolo iliapolo added the @component/cdk8s-core Issue related to cdk8s-core label Sep 20, 2024
@iliapolo iliapolo transferred this issue from cdk8s-team/cdk8s-core Sep 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
@component/cdk8s-core Issue related to cdk8s-core effort/medium 1 week tops feature-request New/Enhanced functionality wanted priority/p2 Dependent on community feedback. PR's are welcome :)
Projects
None yet
Development

No branches or pull requests

3 participants