forked from SocialGouv/dashlord
-
Notifications
You must be signed in to change notification settings - Fork 0
123 lines (108 loc) · 3.77 KB
/
scans.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
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
name: DashLord scans
on:
workflow_dispatch:
schedule:
- cron: "0 1 * * *" # see https://crontab.guru
# allow only one concurrent scan action
concurrency:
cancel-in-progress: true
group: scans
jobs:
init:
runs-on: ubuntu-latest
name: Prepare
outputs:
json: ${{ steps.init.outputs.json }}
steps:
- uses: actions/checkout@v2
- id: init
uses: "DISIC/dashlord-observatoire/actions/airtable-procedures-urls@main"
with:
airtable_api_key: ${{ secrets.AIRTABLE_API_KEY }}
jdma_api_key: ${{ secrets.JDMA_TOKEN }}
updown_api_key: ${{ secrets.UPDOWNIO_API_KEY }}
airtable_base_id: ${{ secrets.AIRTABLE_BASE_ID }}
airtable_procedures_table_name: ${{ secrets.AIRTABLE_TABLE_NAME }}
airtable_editions_table_name: ${{ secrets.AIRTABLE_EDITIONS_TABLE_NAME }}
output: airtable-procedures_urls.json
scans:
runs-on: ubuntu-latest
name: Scan
needs: init
continue-on-error: true
strategy:
fail-fast: false
max-parallel: 2
matrix:
sites: ${{ fromJson(needs.init.outputs.json) }}
steps:
- uses: actions/checkout@v2
- run: |
mkdir scans
- uses: actions/cache@v2
with:
path: "**/node_modules"
key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }}
- name: Déclaration a11y
continue-on-error: true
uses: "socialgouv/dashlord-actions/declaration-a11y@feat/a11y-output-url"
id: declaration-a11y
with:
url: ${{ matrix.sites.link }}
output: scans/declaration-a11y.json
- name: RGAA
continue-on-error: true
if: ${{ steps.declaration-a11y.outputs.url && steps.declaration-a11y.outputs.url != '' }}
uses: "DISIC/dashlord-observatoire/actions/rgaa@main"
with:
declarationUrl: ${{ steps.declaration-a11y.outputs.url }}
output: scans/rgaa.json
- name: JDMA
continue-on-error: true
uses: "DISIC/dashlord-observatoire/actions/jdma@main"
with:
id: ${{ matrix.sites.id }}
startDate: ${{ matrix.sites.startDate }}
endDate: ${{ matrix.sites.endDate }}
output: scans/jdma.json
output2: scans/jdma_3months.json
- name: UpDown
continue-on-error: true
uses: "DISIC/dashlord-observatoire/actions/updown@main"
with:
updownToken: ${{ matrix.sites.updownToken }}
updownApiKey: ${{ secrets.UPDOWNIO_API_KEY }}
startDate: ${{ matrix.sites.startDate }}
endDate: ${{ matrix.sites.endDate }}
output: scans/updown.json
# - name: eco-index
# timeout-minutes: 2
# continue-on-error: true
# uses: "socialgouv/dashlord-actions/ecoindex@v1"
# with:
# url: ${{ matrix.sites.link }}
# output: scans/ecoindex.json
# - name: Lighthouse scan
# continue-on-error: true
# timeout-minutes: 10
# uses: SocialGouv/dashlord-actions/lhci@v1
# with:
# url: ${{ matrix.sites.link }}
# - name: Updown.io checks
# continue-on-error: true
# timeout-minutes: 10
# uses: "MTES-MCT/updownio-action@main"
# with:
# apiKey: ${{ secrets.UPDOWNIO_API_KEY }}
# url: ${{ matrix.sites.link }}
# output: scans/updownio.json
- uses: DISIC/dashlord-observatoire/actions/save@main
with:
id: ${{ matrix.sites.id }}
url: ${{ matrix.sites.link }}
- uses: EndBug/add-and-commit@v7
with:
add: '["results"]'
author_name: ${{ secrets.SOCIALGROOVYBOT_NAME }}
author_email: ${{ secrets.SOCIALGROOVYBOT_EMAIL }}
message: "update: ${{ matrix.sites.link }}"