Diff of /Dockerfile [000000] .. [413088]

Switch to unified view

a b/Dockerfile
1
# Start from the RStudio base image
2
FROM rocker/rstudio:latest
3
4
# dependencies
5
RUN apt-get update
6
RUN apt-get install -y libgdal-dev libfftw3-dev libmagick++-dev cmake libhdf5-dev git libopencv-dev libopencv-features2d-dev  
7
RUN apt-get install -y libssl-dev libcurl4-openssl-dev libgit2-dev libxml2-dev libfontconfig1-dev libharfbuzz-dev libfribidi-dev libfreetype6-dev libpng-dev libtiff5-dev libjpeg-dev libz-dev
8
9
# OpenCV
10
RUN wget https://github.com/opencv/opencv/archive/refs/tags/4.8.1.zip
11
RUN unzip 4.8.1.zip
12
RUN rm 4.8.1.zip
13
RUN wget https://github.com/opencv/opencv_contrib/archive/refs/tags/4.8.1.zip
14
RUN unzip 4.8.1.zip
15
RUN rm 4.8.1.zip
16
RUN mkdir build
17
WORKDIR "build"
18
RUN cmake -D CMAKE_BUILD_TYPE=RELEASE -D CMAKE_INSTALL_PREFIX=/usr/local -D INSTALL_C_EXAMPLES=ON -D INSTALL_PYTHON_EXAMPLES=ON  -D OPENCV_GENERATE_PKGCONFIG=ON -D OPENCV_EXTRA_MODULES_PATH=../opencv_contrib-4.8.1/modules/  -D BUILD_opencv_xfeatures2d=ON ../opencv-4.8.1/
19
RUN make -j5
20
RUN make install
21
RUN sh -c 'echo "/usr/local/lib" > /etc/ld.so.conf.d/opencv.conf'
22
RUN ldconfig
23
24
# Install required R packages
25
RUN R -e "install.packages(c('shiny', 'devtools', 'BiocManager'), repos='http://cran.rstudio.com/')"
26
27
# Install VoltRon dependencies
28
RUN R -e "install.packages(c('grDevices', 'data.table', 'RcppAnnoy', 'RANN', 'Matrix', 'dplyr', 'ggplot2', 'ggrepel', 'igraph', 'irlba', 'rjson', 'magick', 'ids', 'sp', 'reshape2', 'rlang', 'ggpubr', 'shinyjs'), repos='http://cran.rstudio.com/')"
29
RUN R -e "install.packages(c('stringr', 'uwot', 'RCDT'), repos='http://cran.rstudio.com/')"
30
RUN R -e "BiocManager::install(c('EBImage', 'S4Arrays'))"
31
32
# Install Suggested dependencies
33
RUN R -e "BiocManager::install(c('DelayedArray'))"
34
RUN R -e "BiocManager::install(c('HDF5Array'))"
35
RUN R -e "remotes::install_github('bnprks/BPCells/r@v0.3.0')"
36
RUN R -e "remotes::install_github('BIMSBbioinfo/ImageArray')"
37
RUN R -e "remotes::install_github('BIMSBbioinfo/HDF5DataFrame')"
38
RUN R -e "remotes::install_github('BIMSBbioinfo/ZarrDataFrame')"
39
RUN R -e "install.packages('Seurat')"
40
RUN R -e "BiocManager::install('glmGamPoi')"
41
RUN R -e "install.packages('arrow')"
42
RUN R -e "BiocManager::install('RBioFormats')"
43
RUN R -e "BiocManager::install('ComplexHeatmap')"
44
RUN R -e "devtools::install_github('xuranw/MuSiC')"
45
RUN R -e "BiocManager::install('SingleCellExperiment')"
46
RUN R -e "BiocManager::install('SpatialExperiment')"
47
RUN R -e "install.packages('dplyr')"
48
RUN R -e "BiocManager::install('DESeq2')"
49
RUN R -e "install.packages('ggnewscale')"
50
RUN R -e "install.packages('patchwork')"
51
RUN R -e "install.packages('anndata')"
52
RUN R -e "install.packages('R.utils')"
53
RUN R -e "devtools::install_github('immunogenomics/presto')"
54
55
# Install VoltRon dependencies
56
RUN R -e "devtools::install_github('Artur-man/VoltRon')"
57
58
# Install basilisk and setup environment
59
USER rstudio
60
RUN R -e "BiocManager::install('basilisk')"
61
RUN R -e "basilisk::obtainEnvironmentPath(VoltRon::getBasilisk())"
62
RUN sh -c 'echo "options(voltron.python.path = \"/home/rstudio/.cache/R/basilisk/1.18.0/VoltRon/0.2.0/VoltRon_basilisk_env/bin/python\")" > /home/rstudio/.Rprofile'
63
64
# set up java
65
USER root
66
RUN apt-get update -y
67
RUN apt upgrade -y
68
RUN apt-get install -y openjdk-21-jdk
69
RUN export JAVA_HOME=/usr/lib/jvm/java-21-openjdk-arm64/
70
RUN R CMD javareconf -e
71
72
# Install java based packages
73
RUN R -e "install.packages('rJava')"
74
RUN R -e "BiocManager::install('RBioFormats')"
75
RUN sh -c 'echo "options(java.parameters = \"-Xmx10g\")" >> /home/rstudio/.Rprofile'
76
77
# Install spacexr
78
RUN apt-get install -y libgsl-dev
79
RUN R -e "options(timeout = 600000000); devtools::install_github(\"dmcable/spacexr\")"
80
81
# increase cache disk size for ImageMagick
82
RUN sed -i 's/2GiB/10GiB/g' /etc/ImageMagick-6/policy.xml
83
84
# vitessceR
85
RUN apt-get update -y
86
RUN apt upgrade -y
87
RUN apt-get install -y libsodium-dev 
88
RUN R -e "options(timeout = 600000000); devtools::install_github(\"vitessce/vitessceR\")"