-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathr_base_dockerfile
64 lines (57 loc) · 2.42 KB
/
r_base_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
#FROM sd2e/python3:ubuntu18
FROM r-base:3.6.1
# ENV PATH "/opt/bin/:$PATH"
# ADD config.yml /config.yml
# ADD src /opt/src
#RUN sed -i -re 's/([a-z]{2}\.)?archive.ubuntu.com|security.ubuntu.com/old-releases.ubuntu.com/g' /etc/apt/sources.list
# Install R
# RUN export DEBIAN_FRONTEND=noninteractive \
# && apt-get update \
# && apt-get install -y apt-transport-https software-properties-common \
# && apt-key adv --keyserver keyserver.ubuntu.com --recv-keys E298A3A825C0D65DFD57CBB651716619E084DAB9 \
# && add-apt-repository 'deb https://cloud.r-project.org/bin/linux/ubuntu bionic-cran35/' \
# && apt-get update \
# && apt-get -y install libssl-dev \
# libcurl4-openssl-dev \
# libc6 \
# r-base-core \
# r-base \
# r-base-dev \
# libxml2-dev \
# wget
RUN apt-get update && \
apt-get -y install python3.6*
RUN apt-get update && \
apt-get -y install libssl-dev \
libcurl4-openssl-dev \
libc6 \
libxml2-dev \
wget \
python3-dev \
python3-pip
# Install nsmblR and other R packages
RUN Rscript -e 'install.packages("RcppEigen")'
RUN Rscript -e 'install.packages("BiocManager"); BiocManager::install("edgeR")'
RUN Rscript -e 'BiocManager::install("clusterProfiler")'
ADD omics_tools /install/omics_tools
RUN cd /install/omics_tools && \
mkdir data && cd data && \
wget ftp://ftp.ncbi.nlm.nih.gov/gene/DATA/gene2go.gz
#/usr/local/lib/python3.6/dist-packages/omics_tools/data/Bacteria.gene_info
COPY README.md setup.py requirements.txt /install/
RUN cd /install && \
pip3 install . && \
pip3 install FisherExact
RUN apt-get -y install rsync && \
# brittle to the location of they python install, there's definitely
# a better way to do this, should eventually by a paramater or seperate app
rsync -rltv /install/omics_tools/data /usr/local/lib/python3.7/dist-packages/omics_tools/ && \
cd /usr/local/lib/python3.7/dist-packages/omics_tools/ && \
python3 -c 'from annotate_GO_KEGG import check_data_files; check_data_files()' && \
gunzip /usr/local/lib/python3.7/dist-packages/omics_tools/data/gene2go.gz
# Add test data
ADD tests /tests
#ADD src /src
#RUN chmod +x /src/*
#ENTRYPOINT []
CMD bash