Public | Automated Build

Last pushed: 2 years ago
Short Description
JupyterHub notebook container.
Full Description

docker-jupyter

Docker containers for Jupyter. For a standalone, single user Notebook app, see
ptimof/notebook.

Building

docker build -t ptimof/ipython 0-ipython
docker build -t ptimof/scipystack 1-scipystack
docker build -t ptimof/ipython-extras 2-ipython-extras
docker build -t ptimof/notebook 3-notebook   # optional
docker build -t ptimof/systemuser 4-systemuser
docker build -t ptimof/jupyterhub 5-jupyterhub

Alternatively, you may wish to pull these images from Docker Hub:

docker pull ptimof/jupyterhub
docker pull ptimof/systemuser

Setup

If a GitHub application has not yet been created, it can be created
here. Make sure the
callback URL is:

    http://[your_host:8000]/hub/oauth_callback

For example, example.com:8000.

Create a file env in a directory that contains the details from
the GitHub application:

    GITHUB_CLIENT_ID=<client_id>
    GITHUB_CLIENT_SECRET=<client_secret>
    OAUTH_CALLBACK_URL=http://[your_host:8000]/hub/oauth_callback

Ensure that this file is only readable by root:

    chmod 0440 /usr/local/etc/jupyterhub/env

Running

docker run -d -p 8000:8000 -v /var/run/docker.sock:/docker.sock -v /etc/passwd:/srv/jupyterhub/userlist --env-file /usr/local/etc/jupyter/env --net=host --name jupyterhub ptimof/jupyterhub

Debugging

  • If a browser ends up stuck re-directing when attempting to use a server, it probably means that the
    user container needs to be removed. Have the user log out of JupyterHub, and Execute docker rm jupyter-[user].
Docker Pull Command
Owner
ptimof
Source Repository

Comments (3)
ptimof
3 years ago

Hi padrillo,

For a standalone, local, single user installation, it's best to use ptimof/notebook. This won't require any fancy OAuth2 magic with GitHub - it will just run the Notebook app (including the R kernel you're looking for).

Unfortunately, there's not much documentation yet for Jupyter (it's still in early development), but most of the IPython documentation applies - the documentation that's missing is about JupyterHub (the multi-user server enhancement to IPython Notebooks). For your use right now, I wouldn't worry about running JupyterHub just yet - stick to the Notebook image, and when you need multi-user support, then dig into JupyterHub.

padrillo
3 years ago

I also saw the ipython-extras. It has the R kernel that I would like to use. Should I rather use the ipython-extras image? Can it be used standalone? Some usage instructions would be helpful.

padrillo
3 years ago

I'm looking for a Notebook for writing R. This image seems to be able to do that. Excuse my questions, but why do I need to create a Github application? Can't I just run the image locally without any network access (for privacy)?
What could I use the hub image for? Is there any other documentation about Jupyter?