-
Notifications
You must be signed in to change notification settings - Fork 118
75 lines (64 loc) · 2.27 KB
/
load-test.yml
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
name: Load Tests
on:
workflow_call:
inputs:
runtime_tag:
description: "Tag for the runner images"
type: "string"
required: true
# Declare default permissions as read only.
permissions: read-all
env:
GO_VERSION: "~1.22"
# renovate: datasource=github-tags depName=cloud-bulldozer/kube-burner
KUBE_BURNER_VERSION: "v1.7.13"
defaults:
run:
shell: bash
jobs:
run-load-test:
name: Run load Tests
runs-on: ubuntu-22.04
steps:
- name: Check out code
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- name: Cache build tools
id: cache-build-tools
uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4
with:
path: /usr/local/bin/kube-burner
key: kube-burner-${{ env.KUBE_BURNER_VERSION }}
- name: Setup cluster
uses: ./.github/actions/deploy-keptn-on-cluster
with:
runtime_tag: ${{ inputs.runtime_tag }}
- name: Install and expose Prometheus
uses: ./.github/actions/deploy-prometheus-on-cluster
- name: Download kube-burner
env:
BASE_URL: https://github.com/cloud-bulldozer/kube-burner/releases
run: |
curl -fL \
"${BASE_URL}/download/${{ env.KUBE_BURNER_VERSION }}/kube-burner-V${KUBE_BURNER_VERSION#v}-linux-x86_64.tar.gz" \
-o kube-burner-${KUBE_BURNER_VERSION#v}-Linux-x86_64.tar.gz
tar -xf kube-burner-${KUBE_BURNER_VERSION#v}-Linux-x86_64.tar.gz
mv kube-burner /usr/local/bin
sleep 60 # wait to have the node exporter ready already with 60s of data before starting the test
- name: Run load Tests
run: make load-test
- name: Upload results
if: always()
uses: actions/upload-artifact@89ef406dd8d7e03cfd12d9e0a4a378f454709029 # v4.3.5
with:
name: load-tests-results
path: ./collected-metrics
- name: Create reports
if: failure()
working-directory: ./.github/scripts
run: ./create-reports-toolkit.sh
- name: Upload cluster logs
if: failure()
uses: actions/upload-artifact@89ef406dd8d7e03cfd12d9e0a4a378f454709029 # v4.3.5
with:
name: logs-load-tests
path: .github/scripts/logs