-
Notifications
You must be signed in to change notification settings - Fork 3
/
Dockerfile
40 lines (33 loc) · 1.62 KB
/
Dockerfile
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
# Copyright 2021 Rosalind Franklin Institute
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
# either express or implied. See the License for the specific
# language governing permissions and limitations under the License.
FROM nvidia/cuda:11.4.0-base-ubuntu20.04
# Install packages and register python3 as python
RUN echo 'debconf debconf/frontend select Noninteractive' | debconf-set-selections && \
apt-get update -y && apt-get install -y dialog apt-utils && \
apt-get install -y build-essential git wget python3-pip python3-pyqt5 xvfb python3-pytest-xvfb && \
update-alternatives --install /usr/bin/python python /usr/bin/python3 10 && \
update-alternatives --install /usr/bin/pip pip /usr/bin/pip3 10 && \
apt-get autoremove -y --purge && apt-get clean -y && rm -rf /var/lib/apt/lists/*
# Install each piece of external software that Ot2Rec calls
# Install python packages
RUN pip3 install --no-cache-dir --upgrade \
mock pytest pytest-cov PyYAML coverage && \
rm -rf /tmp/* && \
find /usr/lib/python3.*/ -name 'tests' -exec rm -rf '{}' +
# Install Ot2Rec from the current commit
ADD . /usr/local/Ot2Rec
WORKDIR /usr/local/Ot2Rec
RUN pip3 install -e . && \
rm -rf /tmp/* && \
find /usr/lib/python3.*/ -name 'tests' -exec rm -rf '{}' +