-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
81 lines (63 loc) · 1.98 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
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
FROM ubuntu:20.04 as builder
USER root
MAINTAINER cgphelp@sanger.ac.uk
ENV ANALYSE_TA_VER '1.1.0'
# install system tools
RUN apt-get -yq update
RUN apt-get install -yq --no-install-recommends \
locales \
g++ \
make \
gcc \
pkg-config \
python3 python3-dev python3-pip python3-setuptools \
zlib1g-dev libbz2-dev liblzma-dev libcurl4-gnutls-dev \
git
ENV CGP_OPT /opt/wtsi-cgp
RUN mkdir $CGP_OPT
ENV PATH $CGP_OPT/bin:$CGP_OPT/python-lib/bin:$PATH
ENV PYTHONPATH $CGP_OPT/python-lib/lib/python3.8/site-packages
RUN locale-gen en_US.UTF-8
RUN update-locale LANG=en_US.UTF-8
ENV LC_ALL en_US.UTF-8
ENV LANG en_US.UTF-8
# install analyse_ta
RUN pip3 install --upgrade setuptools
RUN pip3 install --install-option="--prefix=$CGP_OPT/python-lib" https://github.com/cancerit/analyse_ta/archive/${ANALYSE_TA_VER}.tar.gz
COPY . .
RUN python3 setup.py sdist
RUN pip3 install --install-option="--prefix=$CGP_OPT/python-lib" dist/$(ls -1 dist/)
FROM ubuntu:20.04
LABEL uk.ac.sanger.cgp="Cancer Genome Project, Wellcome Sanger Institute" \
version="1.1.0" \
description="Tool to perform TA repeat bed coverage analysis"
### security upgrades and cleanup
RUN apt-get -yq update
RUN apt-get install -yq --no-install-recommends \
apt-transport-https \
locales \
ca-certificates \
time \
unattended-upgrades \
python3 \
python-setuptools \
python3-pip \
zlib1g-dev libbz2-dev liblzma-dev libcurl4-gnutls-dev && \
unattended-upgrade -d -v
RUN apt-get autoremove -yq
RUN locale-gen en_US.UTF-8
RUN update-locale LANG=en_US.UTF-8
ENV CGP_OPT /opt/wtsi-cgp
ENV PATH $CGP_OPT/bin:$CGP_OPT/python-lib/bin:$PATH
ENV PYTHONPATH $CGP_OPT/python-lib/lib/python3.8/site-packages
RUN pip3 install --upgrade setuptools
ENV LD_LIBRARY_PATH $OPT/lib
ENV LC_ALL en_US.UTF-8
ENV LANG en_US.UTF-8
RUN mkdir -p $CGP_OPT
COPY --from=builder $CGP_OPT $CGP_OPT
## USER CONFIGURATION
RUN adduser --disabled-password --gecos '' ubuntu && chsh -s /bin/bash && mkdir -p /home/ubuntu
USER ubuntu
WORKDIR /home/ubuntu
CMD ["/bin/bash"]