Generate changelog to release #34
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release Helm | |
on: | |
push: | |
paths: | |
- deploy/helm/Chart.yaml | |
branches: | |
- master | |
- release/** | |
pull_request: | |
branches: | |
- master | |
jobs: | |
deploy_helm: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write # to push chart release and create a release (helm/chart-releaser-action) | |
id-token: write # needed for signing | |
pull-requests: write # needed to create pull-request | |
name: Deploy Helm chart to GitHub pages | |
steps: | |
- name: Checkout Code | |
uses: actions/checkout@v4 | |
with: | |
submodules: true | |
fetch-depth: 0 | |
- name: Setup git user | |
run: | | |
git config --global user.name "$(git --no-pager log --format=format:'%an' -n 1)" | |
git config --global user.email "$(git --no-pager log --format=format:'%ae' -n 1)" | |
- name: Set up Helm | |
uses: azure/[email protected] | |
with: | |
version: v3.9.2 | |
- name: Add dependency chart repos | |
run: | | |
helm repo add prometheus-community https://prometheus-community.github.io/helm-charts | |
- name: Run chart-releaser | |
uses: helm/[email protected] | |
with: | |
charts_dir: deploy | |
packages_with_index: true | |
skip_upload: true | |
env: | |
CR_TOKEN: "${{ secrets.GITHUB_TOKEN }}" | |
- name: Set env | |
if: contains(github.ref, 'skip') | |
run: | | |
echo "CR_GIT_REPO=$(cut -d '/' -f 2 <<< $GITHUB_REPOSITORY)" >> $GITHUB_ENV | |
echo "CR_OWNER=$(cut -d '/' -f 1 <<< $GITHUB_REPOSITORY)" >> $GITHUB_ENV | |
- name: Run chart-releaser | |
if: contains(github.ref, 'skip') | |
env: | |
# for chart-releaser (it is required although probably not used) | |
CR_TOKEN: "${{ secrets.GITHUB_TOKEN }}" | |
# for gh cli | |
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | | |
"./.github/cr.sh" | |
shell: bash |