From f70ba6bff4ed8f3c853a8689e46dd5884558dc38 Mon Sep 17 00:00:00 2001 From: Rory Powell Date: Mon, 9 Jan 2023 08:21:48 +0000 Subject: [PATCH] Add workaround to preserve creation date on chart publishing (#9219) Employ the same workaround added to the chart publishing in `release-develop` workflow. See: https://github.com/Budibase/budibase/pull/9099 --- .github/workflows/release-selfhost.yml | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/.github/workflows/release-selfhost.yml b/.github/workflows/release-selfhost.yml index cbf8a002f4..12fb8f5a9d 100644 --- a/.github/workflows/release-selfhost.yml +++ b/.github/workflows/release-selfhost.yml @@ -67,16 +67,24 @@ jobs: uses: azure/setup-helm@v1 id: helm-install + # due to helm repo index issue: https://github.com/helm/helm/issues/7363 + # we need to create new package in a different dir, merge the index and move the package back - name: Build and release helm chart run: | git config user.name "Budibase Helm Bot" git config user.email "<>" git reset --hard git pull - helm package charts/budibase --version "$RELEASE_VERSION" --app-version "$RELEASE_VERSION" + mkdir sync + echo "Packaging chart to sync dir" + helm package charts/budibase --version "$RELEASE_VERSION" --app-version "$RELEASE_VERSION" --destination sync + echo "Packaging successful" git checkout gh-pages - mv *.tgz docs - helm repo index docs + echo "Indexing helm repo" + helm repo index --merge docs/index.yaml sync + mv -f sync/* docs + rm -rf sync + echo "Pushing new helm release" git add -A git commit -m "Helm Release: ${{ env.RELEASE_VERSION }}" git push