Change copy command to rsync for charts

The Helm-toolkit chart is being added to the STX-O
tarball with no need and that is causing a bug when
trying an upload after an application-delete.

The way the application framework performs the deletion
of the Helm charts changed, and now uses the kustomization
file as a list of all charts that needs to be deleted. Because
the helm-toolit is not present on the kustomization, it fails
to be deleted and the application can't be re-uploaded because
of this Helm chart.

This review changes the copy command from cp to rsync
in order to exclude the helm-toolkit during the copy
of the Helm charts to the staging directory.

Test Plan:
PASS - STX Openstack is built
PASS - STX-O upload and apply
PASS - STX-O remove and delete
PASS - STX-O re-upload

Closes-Bug: 2077759

Change-Id: I5787f7e8209e1f7db302cbac6f9f924f9f0d5f95
Signed-off-by: Daniel Caires <DanielMarques.Caires@windriver.com>
This commit is contained in:
Daniel Caires 2024-08-23 13:53:16 -03:00 committed by Daniel Marques Caires
parent d8a917020f
commit 93d6fe12d5

View File

@ -852,7 +852,7 @@ if [ ! -d "usr/lib/fluxcd" ] || [ ! -d "usr/lib/helm" ]; then
fi
# Stage all the charts
cp -R usr/lib/helm staging/charts
rsync -a usr/lib/helm/ staging/charts/ --exclude=helm-toolkit-*
if [ $? -ne 0 ]; then
echo "Failed to copy the charts from ${BUILD_OUTPUT_PATH}/usr/lib/helm to ${BUILD_OUTPUT_PATH}/staging/charts" >&2
exit 1