generated from pagopa/template-java-spring-microservice
-
Notifications
You must be signed in to change notification settings - Fork 1
65 lines (58 loc) · 1.78 KB
/
07_performance_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
name: Performance Test
on:
# schedule:
# - cron: '35 16 * * *'
workflow_dispatch:
inputs:
environment:
required: true
type: choice
description: Select the Environment
options:
- dev
- uat
test-type:
required: true
type: choice
description: Select the Test Type
options:
- constant
- load
- ramping
- smoke
- soak
- spike
- stress
script-name:
required: true
type: choice
description: Select the Script Name
options:
- create_flow_sequential
- create_flow_parallel
flow-size:
required: true
type: number
description: Select the number of payments sent in flow
default: 100
max-parallel-calls:
required: false
type: number
description: Select the number of maximum API calls in parallel (for each VU)
default: 5
permissions:
id-token: write
contents: read
deployments: write
jobs:
run_performance_test:
name: Test ${{(github.event.inputs == null && 'dev') || inputs.environment }}
runs-on: ubuntu-latest
environment: ${{(github.event.inputs == null && 'dev') || inputs.environment }}
steps:
- name: Checkout repository
uses: actions/checkout@1f9a0c22da41e6ebfa534300ef656657ea2c6707
- name: Run k6 script
run: |
cd ./performance-test
sub_key="${{ secrets.PSP_SUBSCRIPTION_KEY }}" payments_in_flow="${{ inputs.flow-size }}" max_parallel_calls="${{ inputs.max-parallel-calls }}" env="${{ inputs.environment }}" type="${{ inputs.test-type }}" script="${{ inputs.script-name }}" db_name=fdr3_k6 docker compose -f docker-compose.yaml up