Skip to content

Commit c01f9c1

Browse files
committed
update chart details
Signed-off-by: Anand Kumar Singh <anandrkskd@gmail.com>
1 parent 5e96308 commit c01f9c1

3 files changed

Lines changed: 12 additions & 4 deletions

File tree

helm-chart/README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,8 @@ The scripts in this directory automate the process of:
4242
5. Updates `Chart.yaml` with RedHat-specific metadata:
4343
- Sets description to "RedHat Argo CD Agent for connecting managed clusters to a Principal"
4444
- Adds annotation `charts.openshift.io/name` = "RedHat Argo CD Agent - Agent Component"
45-
- Sets version to the ref value from `config.yaml` (e.g., `v0.5.1`)
45+
- Sets version to the ref value from `config.yaml` with "v" prefix removed (e.g., `v0.5.1``0.5.1`)
46+
- Sets appVersion to the same version value (without "v" prefix)
4647
6. Updates `values.yaml` with production image repository:
4748
- Image repository: `registry.redhat.io/openshift-gitops-1/argocd-agent-rhel8`
4849
- Image tag: Provided as argument, should be similar to what is present on the catalog. e.g. v1.18.1, v1.18.1-2
@@ -83,7 +84,8 @@ The scripts in this directory automate the process of:
8384
4. Updates `Chart.yaml` with RedHat-specific metadata:
8485
- Sets description to "RedHat Argo CD Agent for connecting managed clusters to a Principal"
8586
- Adds annotation `charts.openshift.io/name` = "RedHat Argo CD Agent - Agent Component"
86-
- Sets version to the ref value from `config.yaml` (e.g., `v0.5.1`)
87+
- Sets version to the ref value from `config.yaml` with "v" prefix removed (e.g., `v0.5.1``0.5.1`)
88+
- Sets appVersion to the same version value (without "v" prefix)
8789
5. Updates `values.yaml` with stage image repository:
8890
- Image repository: `quay.io/redhat-user-workloads/rh-openshift-gitops-tenant/argocd-agent-rhel8`
8991
- Image tag: Provided as argument

helm-chart/publish-stage.sh

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,9 +162,12 @@ TEMP_VALUES_YAML="${HELM_CHART_OUTPUT_DIR}/values.yaml"
162162

163163
# Update Chart.yaml in the copy
164164
info "Updating Chart.yaml in the copy..."
165+
# Remove 'v' prefix from ref for version (e.g., v0.5.1 -> 0.5.1)
166+
CHART_VERSION="${ARGOCD_AGENT_REF#v}"
165167
"${YQ}" eval '.description = "RedHat Argo CD Agent for connecting managed clusters to a Principal"' -i "${TEMP_CHART_YAML}"
166168
"${YQ}" eval '.annotations."charts.openshift.io/name" = "RedHat Argo CD Agent - Agent Component"' -i "${TEMP_CHART_YAML}"
167-
"${YQ}" eval ".version = \"${ARGOCD_AGENT_REF}\"" -i "${TEMP_CHART_YAML}"
169+
"${YQ}" eval ".version = \"${CHART_VERSION}\"" -i "${TEMP_CHART_YAML}"
170+
"${YQ}" eval ".appVersion = \"${CHART_VERSION}\"" -i "${TEMP_CHART_YAML}"
168171

169172
info "Chart.yaml updated successfully"
170173

helm-chart/publish.sh

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,9 +160,12 @@ TEMP_VALUES_YAML="${HELM_CHART_OUTPUT_DIR}/values.yaml"
160160

161161
# Update Chart.yaml in the copy
162162
info "Updating Chart.yaml in the copy..."
163+
# Remove 'v' prefix from ref for version (e.g., v0.5.1 -> 0.5.1)
164+
CHART_VERSION="${ARGOCD_AGENT_REF#v}"
163165
"${YQ}" eval '.description = "RedHat Argo CD Agent for connecting managed clusters to a Principal"' -i "${TEMP_CHART_YAML}"
164166
"${YQ}" eval '.annotations."charts.openshift.io/name" = "RedHat Argo CD Agent - Agent Component"' -i "${TEMP_CHART_YAML}"
165-
"${YQ}" eval ".version = \"${ARGOCD_AGENT_REF}\"" -i "${TEMP_CHART_YAML}"
167+
"${YQ}" eval ".version = \"${CHART_VERSION}\"" -i "${TEMP_CHART_YAML}"
168+
"${YQ}" eval ".appVersion = \"${CHART_VERSION}\"" -i "${TEMP_CHART_YAML}"
166169

167170
info "Chart.yaml updated successfully"
168171

0 commit comments

Comments
 (0)