-
Notifications
You must be signed in to change notification settings - Fork 7
74 lines (60 loc) · 1.99 KB
/
helm-ci.yaml
File metadata and controls
74 lines (60 loc) · 1.99 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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
name: Helm Chart CI
on:
pull_request:
branches: [main]
env:
HELM_VERSION: v3.18.2
KUBECONFORM_VERSION: 0.7.0
PYTHON_VERSION: 3.13
jobs:
helm-ci:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Helm
uses: azure/setup-helm@v4
with:
version: ${{ env.HELM_VERSION }}
- name: Install helm-unittest plugin
run: |
helm plugin install https://github.com/helm-unittest/helm-unittest
- name: Install kubeconform
run: |
curl -sSLo kubeconform.tar.gz "https://github.com/yannh/kubeconform/releases/download/v${{ env.KUBECONFORM_VERSION }}/kubeconform-linux-amd64.tar.gz"
tar -xzf kubeconform.tar.gz
sudo mv kubeconform /usr/local/bin/
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: ${{ env.PYTHON_VERSION }}
- name: Set up chart-testing
uses: helm/chart-testing-action@v2
- name: Set up yamllint
run: |
pip install yamllint
- name: Check changed charts
run: |
ct lint --chart-dirs geoserver,mapstore --target-branch ${{ github.event.repository.default_branch }} --validate-maintainers=false
- name: GeoServer - Unit Tests
run: |
echo "::group::Unit testing geoserver/latest"
helm unittest geoserver/latest
echo "::endgroup::"
- name: GeoServer - Kubeconform
run: |
echo "::group::Validating geoserver/latest manifests"
helm template geoserver-test geoserver/latest | kubeconform -summary
echo "::endgroup::"
- name: MapStore - Unit Tests
run: |
echo "::group::Unit testing mapstore/latest"
helm unittest mapstore/latest
echo "::endgroup::"
- name: MapStore - Kubeconform
run: |
echo "::group::Validating mapstore/latest manifests"
helm template mapstore-test mapstore/latest | kubeconform -summary
echo "::endgroup::"