forked from opendatahub-io/odh-gitops
-
Notifications
You must be signed in to change notification settings - Fork 1
48 lines (45 loc) · 1.63 KB
/
Copy pathhelm.yaml
File metadata and controls
48 lines (45 loc) · 1.63 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
name: Helm Chart Validation
on:
pull_request:
paths:
- 'charts/**'
workflow_dispatch:
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
fetch-depth: 0
- uses: azure/setup-helm@dda3372f752e03dde6b3237bc9431cdc2f7a02a2 # v5.0.0
- name: Linting Charts
run: |
set -euo pipefail
for chart in $(find charts -name Chart.yaml -exec dirname {} \;); do
helm lint "$chart"
done
- name: Setup Chart Linting
id: lint
uses: helm/chart-testing-action@6ec842c01de15ebb84c8627d2744a0c2f2755c9f # v2.8.0
- name: Run chart-testing (list-changed)
id: list-changed
run: |
changed=$(ct list-changed --config ./.github/configs/ct.yaml)
if [[ -n "$changed" ]]; then
echo "::set-output name=changed::true"
fi
- name: Run chart-testing (lint)
run: ct lint --debug --config ./.github/configs/ct.yaml --lint-conf ./.github/configs/lintconf.yaml
- name: Run chart snapshot tests
run: make chart-test
- name: Use golang
uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0
- name: Generate docs and check for changes
run: |
make helm-docs
if ! git diff --exit-code -- $(find charts -name api-docs.md); then
echo -e '\033[0;31mDocumentation outdated! (Run make helm-docs locally and commit)\033[0m ❌'
exit 1
else
echo -e '\033[0;32mDocumentation up to date\033[0m ✔'
fi