added tools
ci/woodpecker/push/woodpecker Pipeline failed
Details
ci/woodpecker/push/woodpecker Pipeline failed
Details
This commit is contained in:
parent
bd984ae9d9
commit
62d3bd0bc9
184
Dockerfile
184
Dockerfile
|
@ -1,8 +1,12 @@
|
|||
ARG NVIDIA_IMAGE=nvcr.io/nvidia/tensorflow:22.12-tf2-py3
|
||||
|
||||
FROM ${NVIDIA_IMAGE}
|
||||
############################################################################
|
||||
#################### Dependency: jupyter/base-image ########################
|
||||
############################################################################
|
||||
|
||||
#### copied from https://github.com/jupyter/docker-stacks/tree/main/docker-stacks-foundation
|
||||
|
||||
# Copyright (c) Jupyter Development Team.
|
||||
# Distributed under the terms of the Modified BSD License.
|
||||
|
||||
|
@ -97,8 +101,8 @@ RUN mkdir "/home/${NB_USER}/work" && \
|
|||
# Correct permissions
|
||||
# Do all this in a single RUN command to avoid duplicating all of the
|
||||
# files across image layers when the permissions change
|
||||
RUN sleep 120
|
||||
COPY --chown="${NB_UID}:${NB_GID}" ./jupyterlab-datascience-gpu/initial-condarc "${CONDA_DIR}/.condarc"
|
||||
|
||||
COPY --chown="${NB_UID}:${NB_GID}" initial-condarc "${CONDA_DIR}/.condarc"
|
||||
WORKDIR /tmp
|
||||
RUN set -x && \
|
||||
arch=$(uname -m) && \
|
||||
|
@ -139,8 +143,138 @@ USER ${NB_UID}
|
|||
|
||||
WORKDIR "${HOME}"
|
||||
|
||||
|
||||
############################################################################
|
||||
################# Dependency: jupyter/minimal-notebook #####################
|
||||
############################################################################
|
||||
|
||||
# Copyright (c) Jupyter Development Team.
|
||||
# Distributed under the terms of the Modified BSD License.
|
||||
ARG OWNER=jupyter
|
||||
|
||||
LABEL maintainer="Jupyter Project <jupyter@googlegroups.com>"
|
||||
|
||||
# Fix: https://github.com/hadolint/hadolint/wiki/DL4006
|
||||
# Fix: https://github.com/koalaman/shellcheck/wiki/SC3014
|
||||
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
|
||||
|
||||
USER root
|
||||
|
||||
# Install all OS dependencies for fully functional notebook server
|
||||
RUN apt-get update --yes && \
|
||||
apt-get install --yes --no-install-recommends \
|
||||
# Common useful utilities
|
||||
git \
|
||||
nano-tiny \
|
||||
tzdata \
|
||||
unzip \
|
||||
vim-tiny \
|
||||
# Inkscape is installed to be able to convert SVG files
|
||||
inkscape \
|
||||
# git-over-ssh
|
||||
openssh-client \
|
||||
# less is needed to run help in R
|
||||
# see: https://github.com/jupyter/docker-stacks/issues/1588
|
||||
less \
|
||||
# nbconvert dependencies
|
||||
# https://nbconvert.readthedocs.io/en/latest/install.html#installing-tex
|
||||
texlive-xetex \
|
||||
texlive-fonts-recommended \
|
||||
texlive-plain-generic && \
|
||||
apt-get clean && rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# Create alternative for nano -> nano-tiny
|
||||
RUN update-alternatives --install /usr/bin/nano nano /bin/nano-tiny 10
|
||||
|
||||
# Switch back to jovyan to avoid accidental container runs as root
|
||||
USER ${NB_UID}
|
||||
|
||||
############################################################################
|
||||
################# Dependency: jupyter/scipy-notebook #######################
|
||||
############################################################################
|
||||
|
||||
# Copyright (c) Jupyter Development Team.
|
||||
# Distributed under the terms of the Modified BSD License.
|
||||
ARG OWNER=jupyter
|
||||
|
||||
LABEL maintainer="Jupyter Project <jupyter@googlegroups.com>"
|
||||
|
||||
# Fix: https://github.com/hadolint/hadolint/wiki/DL4006
|
||||
# Fix: https://github.com/koalaman/shellcheck/wiki/SC3014
|
||||
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
|
||||
|
||||
USER root
|
||||
|
||||
RUN apt-get update --yes && \
|
||||
apt-get install --yes --no-install-recommends \
|
||||
# for cython: https://cython.readthedocs.io/en/latest/src/quickstart/install.html
|
||||
build-essential \
|
||||
# for latex labels
|
||||
cm-super \
|
||||
dvipng \
|
||||
# for matplotlib anim
|
||||
ffmpeg && \
|
||||
apt-get clean && rm -rf /var/lib/apt/lists/*
|
||||
|
||||
USER ${NB_UID}
|
||||
|
||||
# Install Python 3 packages
|
||||
RUN mamba install --quiet --yes \
|
||||
'altair' \
|
||||
'beautifulsoup4' \
|
||||
'bokeh' \
|
||||
'bottleneck' \
|
||||
'cloudpickle' \
|
||||
'conda-forge::blas=*=openblas' \
|
||||
'cython' \
|
||||
'dask' \
|
||||
'dill' \
|
||||
'h5py' \
|
||||
'ipympl'\
|
||||
'ipywidgets' \
|
||||
'matplotlib-base' \
|
||||
'numba' \
|
||||
'numexpr' \
|
||||
'pandas' \
|
||||
'patsy' \
|
||||
'protobuf' \
|
||||
'pytables' \
|
||||
'scikit-image' \
|
||||
'scikit-learn' \
|
||||
'scipy' \
|
||||
'seaborn' \
|
||||
'sqlalchemy' \
|
||||
'statsmodels' \
|
||||
'sympy' \
|
||||
'widgetsnbextension'\
|
||||
'xlrd' && \
|
||||
mamba clean --all -f -y && \
|
||||
fix-permissions "${CONDA_DIR}" && \
|
||||
fix-permissions "/home/${NB_USER}"
|
||||
|
||||
# Install facets which does not have a pip or conda package at the moment
|
||||
WORKDIR /tmp
|
||||
RUN git clone https://github.com/PAIR-code/facets.git && \
|
||||
jupyter nbextension install facets/facets-dist/ --sys-prefix && \
|
||||
rm -rf /tmp/facets && \
|
||||
fix-permissions "${CONDA_DIR}" && \
|
||||
fix-permissions "/home/${NB_USER}"
|
||||
|
||||
# Import matplotlib the first time to build the font cache.
|
||||
ENV XDG_CACHE_HOME="/home/${NB_USER}/.cache/"
|
||||
|
||||
RUN MPLBACKEND=Agg python -c "import matplotlib.pyplot" && \
|
||||
fix-permissions "/home/${NB_USER}"
|
||||
|
||||
USER ${NB_UID}
|
||||
|
||||
WORKDIR "${HOME}"
|
||||
|
||||
|
||||
|
||||
################ copied from https://github.com/iot-salzburg/gpu-jupyter/tree/master/src
|
||||
|
||||
|
||||
# LABEL authors="Christoph Schranz <christoph.schranz@salzburgresearch.at>, Mathematical Michael <consistentbayes@gmail.com>"
|
||||
|
||||
|
||||
|
@ -184,3 +318,49 @@ RUN git clone https://github.com/Syllo/nvtop.git /run/nvtop && \
|
|||
RUN fix-permissions /home/$NB_USER
|
||||
|
||||
USER $NB_UID
|
||||
|
||||
|
||||
############################################################################
|
||||
############################ Useful packages ###############################
|
||||
############################################################################
|
||||
|
||||
LABEL authors="Christoph Schranz <christoph.schranz@salzburgresearch.at>, Mathematical Michael <consistentbayes@gmail.com>"
|
||||
|
||||
USER root
|
||||
|
||||
RUN pip install --no-cache-dir ipyleaflet "plotly>=4.14.3" "ipywidgets>=7.5"
|
||||
|
||||
# Install important packages and Graphviz
|
||||
RUN set -ex \
|
||||
&& buildDeps=' \
|
||||
graphviz==0.19.1 \
|
||||
' \
|
||||
&& apt-get update \
|
||||
&& apt-get -y install htop apt-utils iputils-ping graphviz libgraphviz-dev openssh-client \
|
||||
&& pip install --no-cache-dir $buildDeps
|
||||
|
||||
# Install various extensions
|
||||
RUN fix-permissions $CONDA_DIR
|
||||
|
||||
# RUN jupyter labextension install @jupyterlab/github
|
||||
# RUN pip install jupyterlab-git
|
||||
RUN pip install jupyterlab-drawio
|
||||
RUN jupyter nbextension enable --py --sys-prefix ipyleaflet
|
||||
RUN jupyter labextension install jupyterlab-plotly
|
||||
RUN jupyter labextension install @jupyter-widgets/jupyterlab-manager plotlywidget
|
||||
# RUN pip install --no-cache-dir jupyter-tabnine --user && \
|
||||
# jupyter nbextension install --py jupyter_tabnine --user && \
|
||||
# jupyter nbextension enable --py jupyter_tabnine --user && \
|
||||
# jupyter serverextension enable --py jupyter_tabnine --user
|
||||
RUN pip install --no-cache-dir jupyter_contrib_nbextensions \
|
||||
jupyter_nbextensions_configurator rise
|
||||
# jupyter nbextension enable codefolding/main
|
||||
RUN jupyter labextension install @ijmbarr/jupyterlab_spellchecker
|
||||
|
||||
RUN fix-permissions /home/$NB_USER
|
||||
|
||||
# Switch back to jovyan to avoid accidental container runs as root
|
||||
USER $NB_UID
|
||||
|
||||
# Copy jupyter_notebook_config.json
|
||||
#COPY jupyter_notebook_config.json /etc/jupyter/
|
Loading…
Reference in New Issue