From d09d681bef4a94be8d55aff37918ebc7f6c76cc6 Mon Sep 17 00:00:00 2001 From: Gabe Cook Date: Wed, 2 Aug 2023 14:40:22 -0500 Subject: [PATCH] :zap: (ci): Improve Chart Releaser CI speed --- .github/workflows/release.yaml | 28 ++++++++++++++++++++++++++-- 1 file changed, 26 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 111c5506c..b8be0e46a 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -44,21 +44,45 @@ jobs: sed -i '/^.* logo/dev/null; then + cr package --package-path=.cr-release-packages "$dir" + changed_charts+="$chart_name," + fi + done + echo "changed_charts=${changed_charts%,}" >> $GITHUB_OUTPUT + + - name: Publish charts + uses: helm/chart-releaser-action@v1.5.0 + if: steps.package_charts.outputs.changed_charts != '' + with: + skip_packaging: true env: - CR_TOKEN: "${{ github.token }}" + CR_TOKEN: ${{ github.token }} CR_SKIP_EXISTING: "true" CR_PAGES_BRANCH: helm-index - name: Login to GitHub Container Registry uses: docker/login-action@v2 + if: steps.package_charts.outputs.changed_charts != '' with: registry: ghcr.io username: ${{ github.actor }} password: ${{ github.token }} - name: Push charts to GHCR + if: steps.package_charts.outputs.changed_charts != '' run: | for pkg in .cr-release-packages/*; do if [ -z "${pkg:-}" ]; then