forked from amalic/Jupyterlab
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathDockerfile
86 lines (71 loc) · 2.14 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
82
83
84
85
86
FROM python:3.8
# Install nicer Bash terminal
RUN git clone --depth=1 https://github.com/Bash-it/bash-it.git ~/.bash_it && \
bash ~/.bash_it/install.sh --silent
# Install NodeJS 12
RUN curl -sL https://deb.nodesource.com/setup_12.x | bash - && \
apt-get upgrade -y && \
apt-get install -y nodejs texlive-latex-extra texlive-xetex && \
rm -rf /var/lib/apt/lists/*
# Install Java
RUN apt-get update -y && \
apt-get install default-jdk -y
# Install packages and extensions for JupyterLab
RUN pip install --upgrade pip && \
pip install --upgrade \
jupyterlab>=2.0.0 \
ipywidgets \
jupyter-lsp \
python-language-server \
jupyterlab-git && \
jupyter labextension install \
@jupyter-widgets/jupyterlab-manager \
@jupyterlab/latex \
jupyterlab-drawio \
jupyterlab-plotly \
@bokeh/jupyter_bokeh \
@krassowski/jupyterlab-lsp \
@jupyterlab/git \
jupyterlab-spreadsheet
# Install SPARQL kernel
RUN pip install sparqlkernel
RUN jupyter sparqlkernel install
# Install IJava kernel
RUN curl -L https://github.com/SpencerPark/IJava/releases/download/v1.3.0/ijava-1.3.0.zip > ijava-kernel.zip
RUN unzip ijava-kernel.zip -d ijava-kernel \
&& cd ijava-kernel \
&& python3 install.py --sys-prefix
# Install jupyter RISE extension (for IJava)
RUN pip install jupyter_contrib-nbextensions RISE \
&& jupyter-nbextension install rise --py --system \
&& jupyter-nbextension enable rise --py --system \
&& jupyter contrib nbextension install --system \
&& jupyter nbextension enable hide_input/main
RUN rm ijava-kernel.zip
RUN rm -rf ijava-kernel
RUN jupyter lab build
COPY bin/entrypoint.sh /usr/local/bin/
COPY config/jupyter_notebook_config.py /root/.jupyter/
# COPY config/ /root/.jupyter/
EXPOSE 8888
VOLUME /notebooks
WORKDIR /notebooks
ENTRYPOINT ["entrypoint.sh"]
## Old pip install for data science:
# jedi==0.15.2 \
# # jupyterlab-lsp does not support 0.17
# jupyterlab_latex \
# plotly \
# bokeh \
# numpy \
# scipy \
# numexpr \
# patsy \
# scikit-learn \
# scikit-image \
# matplotlib \
# ipython \
# pandas \
# sympy \
# seaborn \
# nose \