@@ -2,46 +2,15 @@ name: CI
2
2
on : [push, pull_request]
3
3
jobs :
4
4
build :
5
- if : github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
6
- runs-on : ubuntu-latest
7
- steps :
8
- - uses : actions/checkout@v4
9
- with :
10
- submodules : true
11
- - uses : actions/setup-python@v5
12
- with :
13
- python-version : ' 3.10'
14
- cache : pip
15
- cache-dependency-path : ' **/requirements*.txt'
16
- # Don't install editable projects in the current working directory.
17
- # https://pip.pypa.io/en/latest/reference/pip_install/#install-src
18
- - run : pip install --src $GITHUB_WORKSPACE/../src -r requirements.txt
19
- - if : github.repository == 'open-contracting/standard_profile_template'
20
- run : make update extract
21
- - run : make
22
- # Disable linkcheck as it is too slow for development.
23
- # - run: |
24
- # make linkcheck
25
- # rm -f output.json output.txt
5
+ uses : open-contracting/.github/.github/workflows/ci-profile.yml@main
6
+ secrets :
7
+ private-key : ${{ secrets.PRIVATE_KEY }}
8
+ elasticsearch-password : ${{ secrets.ELASTICSEARCH_PASSWORD }}
9
+ with :
10
+ path-prefix : ' '
11
+ version : ' 1.1'
12
+ production-refs : ' ["refs/heads/1.0", "refs/heads/1.1"]'
13
+ # Linkcheck is slow for development.
14
+ linkcheck : false
26
15
# "ResourceWarning: unclosed file <_io.BufferedWriter name='/dev/null'>"
27
- - run : pytest -W error -W ignore::ResourceWarning
28
- # Deploy the built documentation to the staging directory.
29
- - if : github.event_name == 'push'
30
- uses : shimataro/ssh-key-action@v2
31
- with :
32
- key : ${{ secrets.PRIVATE_KEY }}
33
- known_hosts : standard.open-contracting.org ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGveFGTJ9yyObNGDUCUyzyFkm6Kzh3YqIt1qB7B/KU6E
34
- - if : github.event_name == 'push'
35
- uses : bcomnes/netrc-creds@v3
36
- with :
37
- machine : standard.open-contracting.org
38
- login : manage
39
- password : ${{ secrets.ELASTICSEARCH_PASSWORD }}
40
- - if : github.event_name == 'push' && success() && github.repository != 'open-contracting/standard_profile_template'
41
- env :
42
- PATH_PREFIX : " "
43
- PRODUCTION : ${{ startsWith(github.ref, 'refs/tags') || github.ref == 'refs/heads/latest' || github.ref == 'refs/heads/1.0' || github.ref == 'refs/heads/1.1' }}
44
- RELEASE : ${{ startsWith(github.ref, 'refs/tags') }}
45
- VERSION : " 1.1"
46
- shell : bash
47
- run : curl -sS https://raw.githubusercontent.com/open-contracting/deploy/main/deploy-docs.sh | bash -
16
+ pytest-options : -W ignore::ResourceWarning
0 commit comments