-
Notifications
You must be signed in to change notification settings - Fork 21
55 lines (49 loc) · 1.46 KB
/
ci_validate.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
name: OPTIMADE validator
on: [pull_request]
env:
DEPLOY_PREVIEW: "deploy-preview-${{ github.event.number }}--optimade-providers.netlify.app"
jobs:
check_deploy_preview:
name: Check deploy preview is up
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Wait a maximum of 3 min for the preview site to be up
run: sleep 180
validate_provider_list:
name: Provider index meta-db
runs-on: ubuntu-latest
needs:
check_deploy_preview
steps:
- uses: Materials-Consortia/optimade-validator-action@v2
with:
index: yes
protocol: https
domain: ${DEPLOY_PREVIEW}
path: /
validator version: latest
verbosity: 2
validate_local_index_dbs:
name: All local index meta-dbs
runs-on: ubuntu-latest
needs:
check_deploy_preview
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.9
- name: Install OPTIMADE
run: |
python -m pip install --upgrade pip
pip install -U setuptools
pip install optimade
- name: Run validator for all local index meta-dbs
run: |
providers=$(find src/index-metadbs/ -maxdepth 1 -mindepth 1 -type d -printf ' %f' | cut -d / -f 3 )
sleep 10
for provider in ${providers[@]}; do
optimade-validator -vv --index https://${DEPLOY_PREVIEW}/index-metadbs/${provider}/v1/
done