appversion update #43
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
# --------------------------------------------------------- | |
# Title: Continuous Integration | |
# | |
# Uses: | |
# - https://github.com/helm/chart-testing-action | |
# - https://github.com/helm/kind-action | |
# --------------------------------------------------------- | |
name: CI | |
on: | |
push: | |
branches: | |
- main | |
paths-ignore: | |
- '**/README.md' | |
pull_request: | |
branches: | |
- main | |
workflow_dispatch: | |
concurrency: | |
group: "ci" | |
cancel-in-progress: true | |
env: | |
CHARTS_DIRECTORIES_ARG: "--chart-dirs charts" | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout git repository | |
uses: actions/checkout@v3 | |
with: | |
# note: important to have chart-testing work (see https://github.com/helm/chart-testing/issues/186) | |
fetch-depth: 0 | |
- name: Install Helm | |
uses: azure/setup-helm@v3 | |
- name: Install Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: 3.11 | |
- name: Install chart-testing | |
uses: helm/chart-testing-action@v2.3.1 | |
- name: List changed charts | |
id: list-changed | |
run: | | |
changed=$(ct list-changed ${CHARTS_DIRECTORIES_ARG} --target-branch ${{ github.event.repository.default_branch }}) | |
charts=$(echo "$changed" | tr '\n' ' ' | xargs) | |
if [[ -n "$changed" ]]; then | |
echo "changed=true" >> $GITHUB_OUTPUT | |
echo "changed_charts=$charts" >> $GITHUB_OUTPUT | |
fi | |
- name: Lint charts | |
run: ct lint $CHARTS_DIRECTORIES_ARG --target-branch ${{ github.event.repository.default_branch }} |