Adding nb_conda_kernels to a docker-stacks Docker image with Zero to JupyterHub

repo2docker
#1

I am using Zero to JupyterHub and would like to allow users to install and persist custom conda environments in their workspace. I am a newcomer to the Jupyter ecosystem, so some things (conda environments, jupyter packages, etc) are not clear to me and hope that someone is able to point me in the right direction. I tried to follow the documentation but I am missing something.

When I create my own Dockerfile and add ‘RUN conda install nb_conda_kernels’ on top of the ‘data-science’ notebook, for example, I get duplicated kernels listed in the dropdown–one from the original install and one with [] brackets listing the conda environment. I tried to start with the ‘base-image’ but had the same result, maybe I am not installing the package properly?

What would be the proper way to add nb_conda_kernels to a docker-stacks Docker image so that custom environments can be installed in a user’s /home directory?