-
Notifications
You must be signed in to change notification settings - Fork 2
63 lines (62 loc) · 2.04 KB
/
integration.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
---
name: integration
on:
pull_request:
# push:
# branches:
# - main
# tags:
# - v*
workflow_call:
workflow_dispatch:
inputs:
setenv:
description: setenv (output to envfile)
default: true
type: boolean
required: false
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: false
jobs:
integration:
runs-on: ubuntu-latest
timeout-minutes: 5
permissions:
contents: read
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
- id: dsv
# If using as a template outside of the actual repo, you sould reference like this instead:
# uses: DelineaXPM/dsv-github-action@v1 # renovate: tag=v1
# DelineaXPM/dsv-github-action@main uses the default branch of a public repository
uses: DelineaXPM/dsv-github-action@main # renovate: tag=v1
with:
domain: ${{ secrets.DSV_SERVER }}
clientId: ${{ secrets.DSV_CLIENT_ID }}
clientSecret: ${{ secrets.DSV_CLIENT_SECRET }}
retrieve: |
[
{"secretPath": "ci:tests:dsv-github-action:secret-01", "secretKey": "value1", "outputVariable": "RETURN_VALUE_1"},
{"secretPath": "ci:tests:dsv-github-action:secret-01", "secretKey": "value2", "outputVariable": "RETURN_VALUE_2"}
]
- name: validate-first-value
if: always()
run: |
if [ "${{ env.RETURN_VALUE_1 }}" == "${{ secrets.DSV_EXPECTED_VALUE_1 }}" ]; then
echo "✅ test value is matched"
exit 0
else
echo "::error ❌ mismatch, failed to return test value"
exit 1
fi
- name: validate-second-value
if: always()
run: |
if [ "${{ env.RETURN_VALUE_2 }}" == "${{ secrets.DSV_EXPECTED_VALUE_2 }}" ]; then
echo "✅ test value is matched"
exit 0
else
echo -e "::error ❌ mismatch, failed to return test value"
exit 1
fi