-
Notifications
You must be signed in to change notification settings - Fork 48
192 lines (181 loc) · 6.61 KB
/
github_actions.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
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
name: AlphaPulldown-CI-CD
on:
pull_request:
push:
branches:
- main
release:
types: [published]
workflow_dispatch:
jobs:
build-and-test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.10", "3.11"]
install-type: ["user", "developer"]
defaults:
run:
shell: bash -el {0}
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- uses: conda-incubator/setup-miniconda@v3
with:
environment-file: environment.yml
activate-environment: AlphaPulldown
python-version: ${{ matrix.python-version }}
auto-update-conda: true
use-mamba: true
- if: matrix.install-type == 'user'
run: |
pip install alphapulldown
pip install -U "jax[cuda12]"
- if: matrix.install-type == 'developer'
run: |
pip install .
pip install -U "jax[cuda12]"
# export PYTHONPATH=$PWD/AlphaLink2:$PYTHONPATH
# install dependencies for AlphaLink backend
# pip install torch==1.13.0+cu117 --extra-index-url https://download.pytorch.org/whl/cu117
# pip install setuptools==69.5.1 # Downgrade setuptools to avoid crashes when installing unicore
# git clone https://github.com/dptech-corp/Uni-Core.git
# cd Uni-Core
# python setup.py install --disable-cuda-ext
# cd ..
- run: |
python test/test_python_imports.py
pytest -s test/test_custom_db.py
pytest -s test/test_remove_clashes_low_plddt.py
pytest -s test/test_modelcif.py
pytest -s test/test_features_with_templates.py
pytest -s test/test_post_prediction.py
pytest -s test/test_parse_fold.py
#export PYTHONPATH=$PWD/alphapulldown/analysis_pipeline:$PYTHONPATH
## Test analysis pipeline
#conda install -c bioconda biopandas
#pip install pyrosetta-installer
#python -c 'import pyrosetta_installer; pyrosetta_installer.install_pyrosetta()'
#pytest -s test/test_pdb_analyser.py
#pytest -s test/test_get_good_inter_pae.py
build-fold-container:
runs-on: ubuntu-latest
steps:
- uses: webfactory/[email protected]
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
- uses: actions/checkout@v4
- run: rm -rf /opt/hostedtoolcache
- uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- uses: docker/setup-buildx-action@v3
- name: Build and push fold container
if: github.event_name == 'push'
uses: docker/build-push-action@v5
with:
context: .
file: ./docker/pulldown.dockerfile
push: true
tags: ${{ secrets.DOCKER_USERNAME }}/fold:latest
ssh: default
- name: Build and push fold container with version
if: github.event_name == 'release' && github.event.action == 'published'
uses: docker/build-push-action@v5
with:
context: .
file: ./docker/pulldown.dockerfile
push: true
tags: ${{ secrets.DOCKER_USERNAME }}/fold:${{ github.event.release.tag_name }}
ssh: default
build-alphalink-container:
runs-on: ubuntu-latest
steps:
- uses: webfactory/[email protected]
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
- uses: actions/checkout@v4
- run: rm -rf /opt/hostedtoolcache
- uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- uses: docker/setup-buildx-action@v3
- name: Build and push alphalink container
if: github.event_name == 'push'
uses: docker/build-push-action@v5
with:
context: .
file: ./docker/alphalink.dockerfile
push: true
tags: ${{ secrets.DOCKER_USERNAME }}/alphalink:latest
ssh: default
- name: Build and push alphalink container with version
if: github.event_name == 'release' && github.event.action == 'published'
uses: docker/build-push-action@v5
with:
context: .
file: ./docker/alphalink.dockerfile
push: true
tags: ${{ secrets.DOCKER_USERNAME }}/alphalink:${{ github.event.release.tag_name }}
ssh: default
build-alphafold3-container:
runs-on: ubuntu-latest
steps:
- uses: webfactory/[email protected]
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
- uses: actions/checkout@v4
- run: rm -rf /opt/hostedtoolcache
- uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- uses: docker/setup-buildx-action@v3
- name: Build and push alphafold3 container
if: github.event_name == 'push'
uses: docker/build-push-action@v5
with:
context: .
file: ./docker/alphafold3.dockerfile
push: true
tags: ${{ secrets.DOCKER_USERNAME }}/alphafold3:latest
ssh: default
- name: Build and push alphafold3 container with version
if: github.event_name == 'release' && github.event.action == 'published'
uses: docker/build-push-action@v5
with:
context: .
file: ./docker/alphafold3.dockerfile
push: true
tags: ${{ secrets.DOCKER_USERNAME }}/alphafold3:${{ github.event.release.tag_name }}
ssh: default
build-analysis-container:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: rm -rf /opt/hostedtoolcache
- uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- uses: docker/setup-buildx-action@v3
- name: Build and push analysis container
if: github.event_name == 'push'
uses: docker/build-push-action@v5
with:
context: .
file: ./docker/analysis.dockerfile
push: true
tags: ${{ secrets.DOCKER_USERNAME }}/fold_analysis:latest
- name: Build and push analysis container with version
if: github.event_name == 'release' && github.event.action == 'published'
uses: docker/build-push-action@v5
with:
context: .
file: ./docker/analysis.dockerfile
push: true
tags: ${{ secrets.DOCKER_USERNAME }}/fold_analysis:${{ github.event.release.tag_name }}