Update README.md #128
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: Lint and Test Charts | |
on: | |
pull_request: | |
jobs: | |
lint-test: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4.1.7 | |
with: | |
fetch-depth: 0 | |
# - run: | | |
# sudo cp ./chart_schema.yaml /etc | |
# sudo cp ./lintconf.yaml /etc | |
# - uses: actions/setup-go@v4 | |
# with: | |
# go-version: '1.21' | |
- name: Set up Helm | |
uses: azure/setup-helm@fe7b79cd5ee1e45176fcad797de68ecaf3ca4814 # v4.2.0 | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: '3.x' | |
check-latest: true | |
# - run: | | |
# pip3 install "yamllint==1.27.1" | |
# pip3 install "yamale==3.0.4" | |
# - name: Set up chart-testing | |
# uses: helm/chart-testing-action@v2.6.0 | |
- name: Set up chart-testing | |
uses: helm/chart-testing-action@e6669bcd63d7cb57cb4380c33043eebe5d111992 # v2.6.1 | |
# - run: go install github.com/helm/chart-testing/v3/ct@main | |
# - run: ct version | |
- name: Run chart-testing (list-changed) | |
id: list-changed | |
run: | | |
changed=$(ct list-changed --target-branch ${{ github.event.repository.default_branch }}) | |
if [[ -n "$changed" ]]; then | |
echo "changed=true" >> "$GITHUB_OUTPUT" | |
fi | |
- name: Run chart-testing (lint) | |
if: steps.list-changed.outputs.changed == 'true' | |
run: ct lint --config ct.yaml --target-branch ${{ github.event.repository.default_branch }} | |
- name: Create kind cluster | |
uses: helm/kind-action@v1.5.0 | |
if: steps.list-changed.outputs.changed == 'true' | |
- name: Run chart-testing (install) | |
if: steps.list-changed.outputs.changed == 'true' | |
run: ct install --config ct.yaml --target-branch ${{ github.event.repository.default_branch }} |