Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update Docker image #57

Merged
merged 3 commits into from
Jul 30, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
111 changes: 66 additions & 45 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,51 +1,66 @@
# Jupyter container used for Galaxy IPython (+other kernels) Integration

# from June 2023
FROM jupyter/datascience-notebook:python-3.10
# We want to support Python, R, Julia, Bash and to a lesser degree ansible, octave
# https://jupyter-docker-stacks.readthedocs.io/en/latest/using/selecting.html
# Accoring to the link above we should take scipy-notebook and add additional kernels.
# Since Julia installation seems to be complicated we will take the Julia notebook as base and install separate kernels into separate envs
FROM quay.io/jupyter/julia-notebook:python-3.11

MAINTAINER Björn A. Grüning, [email protected]

ENV DEBIAN_FRONTEND=noninteractive

# Set channels to (defaults) > bioconda > conda-forge
RUN conda config --add channels conda-forge && \
conda config --add channels bioconda
#conda config --add channels defaults

# Pre-installed mamba is raising a conda error:
# "The environment is inconsistent"
RUN conda remove mamba --yes
# Set channels to bioconda > conda-forge
RUN conda config --add channels bioconda && \
conda config --add channels conda-forge && \
conda config --set channel_priority strict && \
conda --version

# Install python and jupyter packages
RUN conda update -n base -c conda-forge conda && \
conda update --yes --all && \
conda install --yes --quiet \
ansible-kernel \
bash_kernel \
bioblend galaxy-ie-helpers \
biopython \
cloudpickle \
cython \
dill \
# octave_kernel \
# Scala
# spylon-kernel \
# Java
# scijava-jupyter-kernel \
jupytext \
jupyterlab-geojson \
jupyterlab-katex \
jupyterlab-fasta \
mamba \
patsy \
pip \
r-xml \
rpy2 \
statsmodels && \
conda clean --all -y

RUN pip install jupyterlab_hdf && \
rm -r ~/.cache/pip
RUN conda install --yes \
bioblend galaxy-ie-helpers \
biopython \
cloudpickle \
cython \
dill \
# https://github.com/anaconda/nb_conda_kernels
nb_conda_kernels \
jupytext \
jupyterlab-geojson \
jupyterlab-katex \
jupyterlab-fasta \
patsy \
pip \
statsmodels && \
##
## Now create separate environments, that are managed by nb_conda_kernels
##
conda create -n ansible-kernel --yes ansible-kernel && \
conda create -n bash-kernel --yes bash_kernel && \
conda create -n octave-kernel --yes octave_kernel && \
conda create -n python-kernel-3.12 --yes python=3.12 ipykernel && \
conda create -n rlang-kernel --yes r-base r-irkernel r-xml rpy2 \
'r-caret' \
'r-crayon' \
'r-devtools' \
'r-e1071' \
'r-forecast' \
'r-hexbin' \
'r-htmltools' \
'r-htmlwidgets' \
'r-irkernel' \
'r-nycflights13' \
'r-randomforest' \
'r-rcurl' \
'r-rmarkdown' \
'r-rodbc' \
'r-rsqlite' \
'r-shiny' \
'r-tidymodels' \
'r-tidyverse' \
'unixodbc' && \
conda clean --all -y && \
chmod a+w+r /opt/conda/ -R

ADD ./startup.sh /startup.sh
#ADD ./monitor_traffic.sh /monitor_traffic.sh
Expand Down Expand Up @@ -75,16 +90,22 @@ ENV DEBUG=false \
REMOTE_HOST=none \
GALAXY_URL=none


# @jupyterlab/google-drive not yet supported

USER root

RUN apt-get -qq update && \
apt-get install -y net-tools procps && \
apt-get autoremove -y && \
apt-get clean && \
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
# R pre-requisites
RUN apt-get update --yes && \
apt-get install --yes --no-install-recommends \
fonts-dejavu \
unixodbc \
unixodbc-dev \
r-cran-rodbc \
gfortran \
net-tools \
procps \
gcc && \
apt-get clean && rm -rf /var/lib/apt/lists/*

# /import will be the universal mount-point for Jupyter
# The Galaxy instance can copy in data that needs to be present to the Jupyter webserver
Expand Down
Loading