Skip to content

Commit

Permalink
re-enable chart testing only on changes
Browse files Browse the repository at this point in the history
  • Loading branch information
rkuo-danswer committed Nov 9, 2024
1 parent 4892cb0 commit 89b149e
Showing 1 changed file with 11 additions and 7 deletions.
18 changes: 11 additions & 7 deletions .github/workflows/pr-helm-chart-testing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
version: v3.14.4

- name: Set up Python
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
Expand All @@ -54,16 +54,20 @@ jobs:
echo "changed=true" >> "$GITHUB_OUTPUT"
fi
# lint all charts if any changes were detected
- name: Run chart-testing (lint)
# if: steps.list-changed.outputs.changed == 'true'
run: ct lint --all --config ct.yaml --target-branch ${{ github.event.repository.default_branch }}
if: steps.list-changed.outputs.changed == 'true'
run: ct lint --config ct.yaml --all
# the following would lint only changed charts, but linting isn't expensive
# run: ct lint --config ct.yaml --target-branch ${{ github.event.repository.default_branch }}

- name: Create kind cluster
# if: steps.list-changed.outputs.changed == 'true'
if: steps.list-changed.outputs.changed == 'true'
uses: helm/kind-action@v1.10.0

- name: Run chart-testing (install)
# if: steps.list-changed.outputs.changed == 'true'
if: steps.list-changed.outputs.changed == 'true'
run: ct install --all --helm-extra-set-args="--set=nginx.enabled=false" --debug --config ct.yaml
# run: ct install --target-branch ${{ github.event.repository.default_branch }}

# the following would install only changed charts, but we only have one chart so
# don't worry about that for now
# run: ct install --target-branch ${{ github.event.repository.default_branch }}

0 comments on commit 89b149e

Please sign in to comment.