From 9e19e836d98c652c4fc42a865b20bb0cdd57e5b0 Mon Sep 17 00:00:00 2001 From: Nitesh Turaga Date: Fri, 29 May 2020 13:15:44 -0400 Subject: [PATCH] Add work-in-progress RStudio-pro-bioconductor image - Add Dockerfile, with sys dependencies installed. - NOTES: IMO, these sys dependencies should just be in the base image just like in terra-jupyter-r, because these sys dependencies allow installation and use of most CRAN and Bioconductor packages. - R version in this image is out of date with version R.3.6.3. The base image needs to be built on a more recent version of R. - Once R-4.0 is used, it's possible to remove installation of Bioconductor packages manually as binary package insallation will be available with the `AnVIL` package. There will be no need of a special Bioconductor image. It can just be `rstudio-pro-base:`, which all users use across the board. cc-ing @rtitle and @mtmorgan for a broader discussion. --- terra-rstudio-pro-bioconductor/CHANGELOG.md | 1 + terra-rstudio-pro-bioconductor/Dockerfile | 130 ++++++++++++++++++++ terra-rstudio-pro-bioconductor/README.md | 5 + 3 files changed, 136 insertions(+) create mode 100644 terra-rstudio-pro-bioconductor/CHANGELOG.md create mode 100644 terra-rstudio-pro-bioconductor/Dockerfile create mode 100644 terra-rstudio-pro-bioconductor/README.md diff --git a/terra-rstudio-pro-bioconductor/CHANGELOG.md b/terra-rstudio-pro-bioconductor/CHANGELOG.md new file mode 100644 index 00000000..8a6fb13f --- /dev/null +++ b/terra-rstudio-pro-bioconductor/CHANGELOG.md @@ -0,0 +1 @@ +## todo diff --git a/terra-rstudio-pro-bioconductor/Dockerfile b/terra-rstudio-pro-bioconductor/Dockerfile new file mode 100644 index 00000000..52c6b323 --- /dev/null +++ b/terra-rstudio-pro-bioconductor/Dockerfile @@ -0,0 +1,130 @@ +FROM rstudio-pro-test:latest + +# This is to avoid the error +# 'debconf: unable to initialize frontend: Dialog' +ENV DEBIAN_FRONTEND noninteractive + +## Create env variables for detecting version +RUN echo "TERRA_R_PLATFORM='terra-rstudio-pro-bioconductor'" >> /opt/R/3.6.3/lib/R/etc/Renviron.site \ + && echo "TERRA_R_PLATFORM_BINARY_VERSION='0.99.0'" >> /opt/R/3.6.3/lib/R/etc/Renviron.site + +# Update apt-get +RUN apt-get update \ + && apt-get install -y --no-install-recommends apt-utils \ + && apt-get install -y dselect \ + && dselect update \ + && apt-get install -y --no-install-recommends \ + pkg-config \ + fortran77-compiler \ + byacc \ + automake \ + ## This section install libraries + libpng-dev \ + libpcre2-dev \ + libnetcdf-dev \ + libhdf5-serial-dev \ + libfftw3-dev \ + libopenbabel-dev \ + libopenmpi-dev \ + libexempi3 \ + libxt-dev \ + libgdal-dev \ + libtiff5-dev \ + libreadline-dev \ + libgsl0-dev \ + libgslcblas0 \ + libgtk2.0-dev \ + libgl1-mesa-dev \ + libglu1-mesa-dev \ + libgmp3-dev \ + libhdf5-dev \ + libncurses-dev \ + libbz2-dev \ + libxpm-dev \ + liblapack-dev \ + libv8-3.14-dev \ + libgtkmm-2.4-dev \ + libmpfr-dev \ + libudunits2-dev \ + libmodule-build-perl \ + libapparmor-dev \ + libgeos-dev \ + libprotoc-dev \ + librdf0-dev \ + libmagick++-dev \ + libpoppler-cpp-dev \ + libprotobuf-dev \ + libperl-dev \ + libz-dev \ + liblzma-dev \ + ## software - perl extentions and modules + libarchive-extract-perl \ + libfile-copy-recursive-perl \ + libcgi-pm-perl \ + libdbi-perl \ + libdbd-mysql-perl \ + libxml-simple-perl \ + ## Databases and other software + sqlite \ + openmpi-bin \ + mpi-default-bin \ + openmpi-common \ + openmpi-doc \ + tcl8.5-dev \ + tk-dev \ + openjdk-8-jdk \ + imagemagick \ + tabix \ + ggobi \ + graphviz \ + protobuf-compiler \ + jags \ + ## Additional resources + xfonts-100dpi \ + xfonts-75dpi \ + biber \ + && apt-get clean \ + && rm -rf /var/lib/apt/lists/* + +## These two libraries don't install in the above section--WHY? +RUN apt-get update \ + && apt-get -y --no-install-recommends install \ + default-jdk \ + libjpeg-dev \ + libjpeg-turbo8-dev \ + libjpeg8-dev \ + && apt-get clean \ + && rm -rf /var/lib/apt/lists/* + +## Python installations +RUN apt-get update \ + && apt-get -y --no-install-recommends install python-dev python-pip python-setuptools\ + && pip install wheel \ + ## Install sklearn and pandas on python + && pip install sklearn \ + pandas \ + pyyaml \ + cwltool \ + && apt-get clean \ + && rm -rf /var/lib/apt/lists/* + +# Install libsbml and xvfb +RUN cd /tmp \ + ## libsbml + && curl -O https://s3.amazonaws.com/linux-provisioning/libSBML-5.10.2-core-src.tar.gz \ + && tar zxf libSBML-5.10.2-core-src.tar.gz \ + && cd libsbml-5.10.2 \ + && ./configure --enable-layout \ + && make \ + && make install \ + ## Clean libsbml, and tar.gz files + && rm -rf /tmp/libsbml-5.10.2 \ + && rm -rf /tmp/libSBML-5.10.2-core-src.tar.gz \ + ## apt-get clean and remove cache + && apt-get clean \ + && rm -rf /var/lib/apt/lists/* + +# Install Bioconductor packages +RUN curl -O https://raw.githubusercontent.com/Bioconductor/anvil-docker/master/anvil-rstudio-bioconductor/install.R \ + && R -f install.R \ + && rm -rf install.R diff --git a/terra-rstudio-pro-bioconductor/README.md b/terra-rstudio-pro-bioconductor/README.md new file mode 100644 index 00000000..ad311424 --- /dev/null +++ b/terra-rstudio-pro-bioconductor/README.md @@ -0,0 +1,5 @@ +Run with + +``` +docker-compose -f docker-compose.yml up -d +```