testsuite icon indicating copy to clipboard operation
testsuite copied to clipboard

[Feature] Redesign manifest generation for helm charts

Open kosstennbl opened this issue 6 months ago • 0 comments

Currently, for generation of manifests from helm charts, we use Helm.generate_manifest_from_templates function, which creates temp_template.yml file with all resources.

There are two problems with this:

  1. Helm template creates unneeded information: notes, helm-specific resources. That makes it harder to parse created manifest and requires additional code to handle removal of this info.
  2. temp_template.yml is a confusing name for a file with manifests for resources in Kubernetes. Additionally, that file is being created multiple times: in cnfs/<release_name>/temp_template.yml (seems intended and logical), and in cnfs/temp_template.yml, which doesn't make much sense. That seems to be happening due to call of export_manifest in generate_config.cr during setup process.

Proposed solution:

  1. Create function for gathering manifest from helm deployment based on helm get manifest.
  2. Replace Helm.generate_manifest_from_templates function, remove or rename of all template-related functionality and code.
  3. Rename of temp_template.yml to something reasonable and less confusing (i.e. - generated_manifest.yml)
  4. Fix export_manifest usage (no manifest file should be created in cnfs directory)

kosstennbl avatar Aug 05 '24 13:08 kosstennbl