Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix: export_published_chart correctly detects and exports tar file (c…
…nti-testcatalog#2052) * Fix: export_published_chart correctly detects and export tar file Refs: cnti-testcatalog#1947 - Fixes the issue where multiple tar files caused the Tar module to fail due to globbing, by selecting a single tgz file. - There was a line that was supposed to delete the tgz file (no idea why): FileUtils.rm_rf(tgz_name), which did not actually work due to the previously mentioned globbing, it was removed because it would now cause the program to fail. Signed-off-by: svteb <[email protected]> * Fix: Better handling of undesired states Refs: cnti-testcatalog#1947 - Backtracked on removal of: FileUtils.rm_rf(tgz_name), made it functional through Dir.glob("#{Helm.chart_name(helm_chart)}-*.tgz"). Through this addition a state where multiple tgz archives are present is not possible. - Also added an exception in case a prior helm failure happens and no archive is pulled (not sure whether this state can be reached). Signed-off-by: svteb <[email protected]> * Fix: minor refactor of tgz functions and clarified outputs - Dir.glob functionality for getting tgz files in the working directory abstracted into a function - get_tgz_name function made more generic - outputs made more explicit Signed-off-by: svteb <[email protected]> * Fix: Minor abstraction addition and use of warn log instead of info Signed-off-by: svteb <[email protected]> --------- Signed-off-by: svteb <[email protected]>
- Loading branch information