@@ -3,101 +3,95 @@ name: Integration testing
3
3
on : push
4
4
5
5
jobs :
6
- build :
6
+ build :
7
7
name : Build Docker image
8
8
runs-on : ubuntu-latest
9
9
steps :
10
- - uses : actions/checkout@v2
11
- name : Checkout source tree
12
- - uses : nick-invision/retry@v1
13
- name : Build docker image
14
- with :
15
- timeout_minutes : 10
16
- max_attempts : 3
17
- command : docker build . --file docker/Dockerfile --tag synbiohub/synbiohub:snapshot-standalone
18
- - name : Package image
19
- run : |
20
- docker save synbiohub/synbiohub:snapshot-standalone | gzip > sbh.tar.gz
21
- - uses : actions/upload-artifact@v2
22
- name : Upload Docker image
23
- with :
24
- name : sbh-image
25
- path : sbh.tar.gz
10
+ - uses : actions/checkout@v2
11
+ name : Checkout source tree
12
+ - uses : nick-invision/retry@v1
13
+ name : Build docker image
14
+ with :
15
+ timeout_minutes : 10
16
+ max_attempts : 3
17
+ command : docker build . --file docker/Dockerfile --tag synbiohub/synbiohub:snapshot-standalone
18
+ - name : Package image
19
+ run : |
20
+ docker save synbiohub/synbiohub:snapshot-standalone | gzip > sbh.tar.gz
21
+ - uses : actions/upload-artifact@v4
22
+ name : Upload Docker image
23
+ with :
24
+ name : sbh-image
25
+ path : sbh.tar.gz
26
26
sboltests :
27
27
name : SBOL Test Suite
28
28
needs : build
29
29
runs-on : ubuntu-latest
30
30
steps :
31
- - uses : actions/checkout@v2
32
- name : Checkout source tree
33
- - uses : actions/download-artifact@v2
34
- name : Download Docker image
35
- with :
36
- name : sbh-image
37
- - name : Import saved Docker image
38
- run : |
39
- cat sbh.tar.gz | docker load
40
- - uses : actions/setup-python@v1
41
- name : Install Python
42
- with :
43
- python-version : ' 3.6 ' # To match the one in Travis
44
- - name : Install test dependencies
45
- run : |
46
- pip install -r tests/test_requirements.txt
47
- - uses : nick-invision/retry@v1
48
- name : Run test suite
49
- with :
50
- timeout_minutes : 10
51
- max_attempts : 3
52
- command : tests/sbolsuite.sh
31
+ - uses : actions/checkout@v2
32
+ name : Checkout source tree
33
+ - uses : actions/download-artifact@v4
34
+ name : Download Docker image
35
+ with :
36
+ name : sbh-image
37
+ - name : Import saved Docker image
38
+ run : |
39
+ cat sbh.tar.gz | docker load
40
+ - uses : actions/setup-python@v4
41
+ name : Install Python
42
+ with :
43
+ python-version : ' 3.9 ' # To match the one in Travis
44
+ - name : Install test dependencies
45
+ run : |
46
+ pip install -r tests/test_requirements.txt
47
+ - uses : nick-invision/retry@v1
48
+ name : Run test suite
49
+ with :
50
+ timeout_minutes : 10
51
+ max_attempts : 3
52
+ command : tests/sbolsuite.sh
53
53
sbhtests :
54
54
name : SynBioHub Test Suite
55
55
needs : build
56
56
runs-on : ubuntu-latest
57
57
steps :
58
- - uses : actions/checkout@v2
59
- name : Checkout source tree
60
- - uses : actions/download-artifact@v2
61
- name : Download Docker image
62
- with :
63
- name : sbh-image
64
- - name : Import saved Docker image
65
- run : |
66
- cat sbh.tar.gz | docker load
67
- - uses : actions/setup-python@v1
68
- name : Install Python
69
- with :
70
- python-version : ' 3.6 ' # To match the one in Travis
71
- - name : Install test dependencies
72
- run : |
73
- pip install -r tests/test_requirements.txt
74
- - name : Run tests
75
- run : |
76
- tests/test.sh --stopaftertestsuite
58
+ - uses : actions/checkout@v2
59
+ name : Checkout source tree
60
+ - uses : actions/download-artifact@v4
61
+ name : Download Docker image
62
+ with :
63
+ name : sbh-image
64
+ - name : Import saved Docker image
65
+ run : |
66
+ cat sbh.tar.gz | docker load
67
+ - uses : actions/setup-python@v4
68
+ name : Install Python
69
+ with :
70
+ python-version : ' 3.9 ' # To match the one in Travis
71
+ - name : Install test dependencies
72
+ run : |
73
+ pip install -r tests/test_requirements.txt
74
+ - name : Run tests
75
+ run : |
76
+ tests/test.sh --stopaftertestsuite
77
77
publish :
78
78
name : Publish snapshot image
79
79
needs : [sboltests, sbhtests]
80
80
runs-on : ubuntu-latest
81
81
if : endsWith(github.ref, 'master')
82
82
steps :
83
- - uses : actions/download-artifact@v2
84
- name : Download Docker iamge
85
- with :
86
- name : sbh-image
87
- - name : Import saved Docker image
88
- run : |
89
- cat sbh.tar.gz | docker load
90
- - uses : azure/docker-login@v1
91
- name : Log into Docker Hub
92
- with :
93
- username : ${{ secrets.DOCKER_USERNAME }}
94
- password : ${{ secrets.DOCKER_PASSWORD }}
95
- - name : Push the image to Docker Hub
96
- run : |
97
- docker push synbiohub/synbiohub:snapshot-standalone
98
- - name : Trigger SD2 redeploy
99
- env :
100
- SD2_USER : ${{ secrets.SD2_USER }}
101
- SD2_TOKEN : ${{ secrets.SD2_TOKEN }}
102
- run : |
103
- curl -X POST --user $SD2_USER:$SD2_TOKEN https://jenkins.sd2e.org/job/Synbiohub/job/Redeploy%20to%20dev%20server/build
83
+ - uses : actions/download-artifact@v4
84
+ name : Download Docker iamge
85
+ with :
86
+ name : sbh-image
87
+ - name : Import saved Docker image
88
+ run : |
89
+ cat sbh.tar.gz | docker load
90
+ - uses : azure/docker-login@v1
91
+ name : Log into Docker Hub
92
+ with :
93
+ username : ${{ secrets.DOCKER_USERNAME }}
94
+ password : ${{ secrets.DOCKER_PASSWORD }}
95
+ - name : Push the image to Docker Hub
96
+ run : |
97
+ docker push synbiohub/synbiohub:snapshot-standalone
0 commit comments