Starting any Jupyter Notebook in a JupyterHub with a file .ipynb

Hello guys,

I’m implementing a JupyterHub in a cloud using Docker. When a new user is created a new container in Docker is created for that user. I’d like to put a file .ipynb inside the volume of the user container such that every new user would has acess to this file since the first time using his Jupyter Notebook. I can do this manualy by coping the file to his volume inside his container, however, I’d like that this operation was automatic every new container created to the user.
Is it possible? How to do?

P.S.: it’s the first time I’m using Docker.

Do you use the default docker image from jupyter?
There are two ways for you, but all are create a new docker image based on the default one:

  1. copy the .ipynb file you want in the runtime container and rebuild a new image.
  2. edit a .Dockerfile file like this :
FROM jupyter/base-notebook
COPY <source path>  <taget path>
1 Like

thank you 00Kai0!
That’s it!

=)