Commit 1b54c4bc authored by Jean-Philippe Evrard's avatar Jean-Philippe Evrard
Browse files

Fix chart linter

Without this patch, the lint action incorrectly returns everything
is fine.

This is a problem, as lint effectively is not running, and
therefore we could merge broken charts.

This fixes it by updating to the latest practices you can find
in the official chart-repo-actions.

(See the official example in
ihttps://github.com/helm/charts-repo-actions-demo/blob/1a9640d9983d983404862daee9563fd871db3874/.github/workflows/lint-test.yaml)
parent c62fa362
......@@ -16,12 +16,19 @@ jobs:
with:
fetch-depth: "0"
- name: Lint charts
uses: helm/chart-testing-action@v2.0.1
- uses: actions/setup-python@v2
with:
command: lint
config: .github/ct.yaml
python-version: 3.7
# Helm is already present in github actions, so do not re-install it
- name: Setup chart testing
uses: helm/chart-testing-action@v2.0.1
- name: Run chart testing
run: ct lint --config .github/ct.yaml
# We create two jobs instead of one to make those parallel.
# GH should cancel the rest of the workflow if lint is failing.
test-chart:
name: Install helm chart
runs-on: ubuntu-latest
......@@ -31,11 +38,16 @@ jobs:
with:
fetch-depth: "0"
- uses: actions/setup-python@v2
with:
python-version: 3.7
# Helm is already present in github actions, so do not re-install it
- name: Setup chart testing
uses: helm/chart-testing-action@v2.0.1
- name: Create default kind cluster
uses: helm/kind-action@v1.1.0
- name: Install chart with chart-testing-action
uses: helm/chart-testing-action@v2.0.1
with:
command: install
config: .github/ct.yaml
- name: Install chart with chart-testing
run: ct install
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment