Skip to content

Adding test models to helm chart #111

Adding test models to helm chart

Adding test models to helm chart #111

# See https://github.com/helm/chart-testing-action
name: Lint and Test Charts
on:
push:
branches:
- main
pull_request:
workflow_dispatch:
jobs:
lint-test:
runs-on: ubuntu-latest
# strategy:
# matrix:
# k8s: ["1.19.16", "1.21.14", "1.22.9", "1.23.12", "1.24.7", "1.25.2"]
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Install Helm
uses: azure/setup-helm@v3
# as of 2022/12 the set-output still not fixed in this action
# https://github.com/Azure/setup-helm/issues/103
with:
version: v3.12.1
- uses: actions/setup-python@v4
with:
python-version: '3.10'
check-latest: true
- name: Install chart-testing
uses: helm/[email protected]
- 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 }} --all --debug
- name: Create kind cluster
uses: helm/[email protected]
with:
config: kind-config.yaml
- 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 }} --helm-extra-args "--timeout 600s"
# See https://github.com/helm/chart-testing/blob/main/doc/ct_install.md