-
Notifications
You must be signed in to change notification settings - Fork 0
86 lines (79 loc) · 2.39 KB
/
sanity-check-main.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
77
78
79
80
81
82
83
84
85
86
name: sanity-check-for-BE
# Controls when the workflow will run
on:
workflow_dispatch:
# Triggers the workflow every 30 minutes
schedule:
- cron: "*/30 * * * *"
# push:
# branches:
# - main
concurrency:
group: sanity
cancel-in-progress: false
jobs:
eu-test:
permissions:
contents: write
actions: read
name: sanity-check-eu
uses: ./.github/workflows/sanity-check-eu.yaml # @sanity_check
with:
RETRY_JOB: false
BINARY_TESTS: '[
"scan_nsa_and_submit_to_backend"
]'
secrets: inherit
us-test:
permissions:
contents: write
actions: read
name: sanity-check-us
uses: ./.github/workflows/sanity-check-us.yaml
with:
RETRY_JOB: false
BINARY_TESTS: '[
"scan_nsa_and_submit_to_backend"
]'
secrets: inherit
# better-up-time:
# needs: [eu-test, us-test]
# name: better-up-time
# runs-on: ubuntu-latest
# if: failure()
# #if: ${{ contains(needs.*.result, 'failure') }}
# steps:
# - run: |
# curl --request POST \
# --url https://betteruptime.com/api/v2/incidents \
# --header "Authorization: Bearer ${{ secrets.BETTER_UPTIME_TOKEN }}" \
# --header 'Content-Type: application/json' \
# --data '{"summary": "Production Incident","sms": "false", "email": "true", "call": "true", "requester_email": "borisv@armosec.io", "description": "Sanity check failed ! "}'
call-eu-reran:
permissions:
contents: write
actions: read
needs: [eu-test]
if: ${{ failure() && needs.eu-test.result != 'success' }} # Run only if eu-test fails
name: repeated-eu-test
uses: ./.github/workflows/sanity-check-eu.yaml # @sanity_check
with:
RETRY_JOB: true
BINARY_TESTS: '[
"scan_nsa_and_submit_to_backend"
]'
secrets: inherit
call-us-reran:
permissions:
contents: write
actions: read
needs: [us-test]
if: ${{ failure() && needs.us-test.result != 'success' }} # Run only if us-test fails
name: repeated-us-test
uses: ./.github/workflows/sanity-check-us.yaml # @sanity_check
with:
RETRY_JOB: true
BINARY_TESTS: '[
"scan_nsa_and_submit_to_backend"
]'
secrets: inherit