-
Notifications
You must be signed in to change notification settings - Fork 2
76 lines (66 loc) · 2.43 KB
/
ci-scheduled.yaml
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
75
76
#
# Copyright 2020 The dNation Kubernetes Monitoring Stack Authors. All Rights Reserved.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
name: Test Chart with k8s versions
on:
schedule:
# Run every 2 weeks
- cron: "0 0 1,15 * *"
jobs:
test-chart:
name: test-chart
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
include:
- k8s-version: v1.19.7
stack-version: v1.3
- k8s-version: v1.20.2
stack-version: v1.3
- k8s-version: v1.20.7
stack-version: v1.4
- k8s-version: v1.21.2
stack-version: v1.4
- k8s-version: v1.22.1
stack-version: v1.4
- k8s-version: v1.23.13
stack-version: v2.4
- k8s-version: v1.25.9
stack-version: v2.5
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Fetch history
run: git fetch --prune --unshallow
- name: Complete semVer with highest patch version
id: highest-patch
run: |
tag=$(git tag -l --sort=-v:refname | grep -F ${{ matrix.stack-version }}. | head -1)
[[ -z $tag ]] && (echo "Patch version for ${{ matrix.stack-version }} not found!" && exit 1)
echo "::set-output name=version::${tag//v}"
- name: Download correct chart
run: |
echo ${{ steps.semver.outputs.version }}
wget https://dnationcloud.github.io/helm-hub/dnation-kubernetes-monitoring-stack-${{ steps.highest-patch.outputs.version }}.tgz
tar -xvf dnation-kubernetes-monitoring-stack-${{ steps.highest-patch.outputs.version }}.tgz
- name: Create kind ${{ matrix.k8s-version }} cluster
uses: helm/kind-action@v1.2.0
with:
node_image: kindest/node:${{ matrix.k8s-version }}
- name: Set up chart-testing
uses: helm/chart-testing-action@v2.1.0
- name: Run chart-testing (install)
run: |
ct install --config .github/ct-scheduled.yaml