Skip to content

Commit

Permalink
ci: simplify helm workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
yorugac committed Aug 21, 2024
1 parent 40dce3f commit e9f2a5b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 17 deletions.
8 changes: 1 addition & 7 deletions .github/workflows/helm-lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,4 @@ jobs:

- name: Run chart-testing (lint)
run: |
# is there a better way to get the right name for branch?
# for ref.: https://github.com/helm/chart-testing/issues/186#issuecomment-585595379
if [[ "${{ github.event_name }}" == "pull_request" ]]; then
ct lint --target-branch ${{ github.head_ref }} --config ./charts/ct.yaml
else
ct lint --target-branch ${{ github.ref_name }} --config ./charts/ct.yaml
fi
ct lint --config ./charts/ct.yaml
12 changes: 2 additions & 10 deletions .github/workflows/helm-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,7 @@ jobs:
- name: Run chart-testing (list-changed)
id: list-changed
run: |
if [[ "${{ github.event_name }}" == "pull_request" ]]; then
changed=$(ct list-changed --config ./charts/ct.yaml --target-branch ${{ github.head_ref }})
else
changed=$(ct list-changed --config ./charts/ct.yaml --target-branch ${{ github.ref_name }})
fi
changed=$(ct list-changed --config ./charts/ct.yaml
if [[ -n "$changed" ]]; then
echo "changed=true" >> $GITHUB_OUTPUT
Expand All @@ -52,8 +48,4 @@ jobs:
- name: Run chart-testing (install)
if: steps.list-changed.outputs.changed == 'true'
run: |
if [[ "${{ github.event_name }}" == "pull_request" ]]; then
ct install --target-branch ${{ github.head_ref }} --charts ./charts/
else
ct install --target-branch ${{ github.ref_name }} --charts ./charts/
fi
ct install --charts ./charts/

0 comments on commit e9f2a5b

Please sign in to comment.