Skip to content

Revert "Fix Helm chart appVersion not being quoted in index.yaml"

Radamanthus Batnag requested to merge 490699-revert-appversion-quoting into master

What does this MR do and why?

Revert "Fix Helm chart appVersion not being quoted in index.yaml"

This reverts merge request !166663 (merged)

The presenter is quoting not just numeric values in appVersion, but also string values that do not need to be quoted.

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Screenshots or screen recordings

NA

How to set up and validate locally

Preliminaries

  • prepare a project (get the project ID)
  • a personal access token with scope set to api
  • We need two helm charts, one with a string version (e.g. master, and one with a numeric version (e.g. 4852e004). We'll verify that this MR keeps the fix for numeric versions done by !166663 (merged), and fixes the issue for string versions introduced by !166663 (merged)

Testing proper

  1. Add the bananas repo to helm: helm repo add --username root --password glpat-zzz bananas http://gdk.test:3000/api/v4/projects/7/packages/helm/bananas

  2. Create and upload a package:

  • helm create mypackage
  • edit stringversion/Chart.yaml - change the value of appVersion to master
  • helm package mypackage
  • curl --fail --request POST --user <user>:<personal-access-token> --form "chart=@mypackage-0.1.0.tgz" "http://gdk.test:3000/api/v4/projects/<project-id>/packages/helm/api/bananas/charts";
  1. helm repo update
  2. helm search repo

The APP VERSION output should not be quoted:

NAME                          	CHART VERSION	APP VERSION	DESCRIPTION                                                  
bananas/mypackage         	0.1.0        	master     	A Helm chart for Kubernetes   

Related to #490699

Merge request reports

Loading