diff --git a/.github/workflows/helm.yml b/.github/workflows/helm.yml index 554bd13d..17df884e 100644 --- a/.github/workflows/helm.yml +++ b/.github/workflows/helm.yml @@ -1,15 +1,11 @@ name: Helm on: - push: - branches: - - main - paths: - - 'deploy/chart/**' pull_request: paths: - 'deploy/chart/**' workflow_dispatch: {} + release: {} permissions: contents: read @@ -26,8 +22,8 @@ jobs: - name: Set Version run: | TAG=$(git describe --tags --abbrev=0) - sed -ie "s/appVersion: \"latest\"/appVersion: ${TAG}/g" deploy/chart/Chart.yaml - sed -ie "s/version: 0.0.0/version: ${TAG}/g" deploy/chart/Chart.yaml + sed -ie "s/appVersion: \"latest\"/appVersion: ${TAG#helm-}/g" deploy/chart/Chart.yaml + sed -ie "s/version: 0.0.0/version: ${TAG#helm-}/g" deploy/chart/Chart.yaml - name: Set up Helm uses: azure/setup-helm@v3 @@ -65,8 +61,8 @@ jobs: - name: Set Version run: | TAG=$(git describe --tags --abbrev=0) - sed -ie "s/appVersion: \"latest\"/appVersion: ${TAG}/g" deploy/chart/Chart.yaml - sed -ie "s/version: 0.0.0/version: ${TAG}/g" deploy/chart/Chart.yaml + sed -ie "s/appVersion: \"latest\"/appVersion: ${TAG#helm-}/g" deploy/chart/Chart.yaml + sed -ie "s/version: 0.0.0/version: ${TAG#helm-}/g" deploy/chart/Chart.yaml - name: Configure Git run: | @@ -80,8 +76,7 @@ jobs: uses: helm/chart-releaser-action@v1.6.0 env: CR_TOKEN: "${{ secrets.GITHUB_TOKEN }}" - CR_RELEASE_NAME_TEMPLATE: "{{ .Version }}" + CR_RELEASE_NAME_TEMPLATE: "helm-{{ .Version }}" with: charts_dir: deploy skip_existing: true - packages_with_index: true