Skip to content

Commit 7361a6d

Browse files
authored
Merge pull request #118 from gaelforget/dev_jupyter_kernel_fix
Dev jupyter kernel fix
2 parents 04015c6 + 9300561 commit 7361a6d

File tree

4 files changed

+22
-3187
lines changed

4 files changed

+22
-3187
lines changed

Dockerfile

Lines changed: 19 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -2,28 +2,18 @@ FROM jupyter/base-notebook:latest
22

33
USER root
44

5-
RUN apt-get update && \
6-
apt-get install -y --no-install-recommends build-essential && \
7-
apt-get install -y --no-install-recommends vim && \
8-
apt-get install -y --no-install-recommends curl && \
9-
apt-get install -y --no-install-recommends git-all && \
10-
apt-get install -y --no-install-recommends unzip && \
11-
apt-get install -y --no-install-recommends gfortran && \
12-
apt-get install -y --no-install-recommends openmpi-bin && \
13-
apt-get install -y --no-install-recommends libopenmpi-dev && \
14-
apt-get install -y --no-install-recommends libnetcdf-dev && \
15-
apt-get install -y --no-install-recommends libnetcdff-dev && \
16-
apt-get clean && rm -rf /var/lib/apt/lists/*
5+
ENV mainpath=/home/jovyan/
6+
RUN mkdir -p ${mainpath}
177

18-
USER ${NB_USER}
8+
RUN apt-get update
199

20-
ENV mainpath=/home/${NB_USER}
10+
RUN apt-get install -y --no-install-recommends build-essential && \
11+
apt-get install -y --no-install-recommends vim && \
12+
apt-get install -y --no-install-recommends git && \
13+
apt-get install -y --no-install-recommends curl && \
14+
apt-get install -y --no-install-recommends unzip
2115

22-
RUN echo 'alias julia="${mainpath}/.juliaup/bin/julia --project=${mainpath}"' >> ~/.bashrc
23-
RUN curl -fsSL https://install.julialang.org | sh -s -- --yes
24-
25-
USER root
26-
RUN ln -s ${mainpath}/.juliaup/bin/julia /usr/local/bin/julia
16+
RUN apt-get clean && rm -rf /var/lib/apt/lists/*
2717

2818
USER ${NB_USER}
2919

@@ -32,20 +22,21 @@ COPY --chown=${NB_USER}:users ./src/plutoserver ${mainpath}/plutoserver
3222

3323
RUN cp ${mainpath}/src/setup.py ${mainpath}/setup.py
3424
RUN cp ${mainpath}/src/runpluto.sh ${mainpath}/runpluto.sh
35-
RUN cp ${mainpath}/src/environment.yml ${mainpath}/environment.yml
3625
RUN cp ${mainpath}/src/Project.toml ${mainpath}/Project.toml
37-
RUN cp ${mainpath}/src/Manifest.toml ${mainpath}/Manifest.toml
26+
27+
RUN echo 'alias julia="${mainpath}/.juliaup/bin/julia --project=${mainpath}"' >> ~/.bashrc
3828

39-
RUN ${mainpath}/.juliaup/bin/julia -e "import Pkg; Pkg.update(); Pkg.instantiate();"
29+
RUN conda config --env --add channels conda-forge
30+
RUN conda config --env --add channels r
31+
32+
RUN curl -fsSL https://install.julialang.org | sh -s -- --yes
33+
34+
RUN ${mainpath}/.juliaup/bin/julia --project=${mainpath} -e "import Pkg; Pkg.update(); Pkg.instantiate();"
35+
RUN ${mainpath}/.juliaup/bin/julia --project=${mainpath} ${mainpath}/src/download_notebooks.jl
36+
RUN ${mainpath}/.juliaup/bin/julia --project=${mainpath} ${mainpath}/src/warmup1.jl
4037

4138
RUN jupyter lab build && \
4239
jupyter lab clean && \
4340
pip install ${mainpath} --no-cache-dir && \
4441
rm -rf ~/.cache
4542

46-
RUN ${mainpath}/.juliaup/bin/julia --project=${mainpath}/src ${mainpath}/src/warmup1.jl
47-
RUN ${mainpath}/.juliaup/bin/julia --project=${mainpath}/src ${mainpath}/src/download_notebooks.jl
48-
49-
RUN mkdir .dev
50-
RUN mv build plutoserver.egg-info .dev
51-

0 commit comments

Comments
 (0)