GithubHelp home page GithubHelp logo

0dbd / jupyterhub Goto Github PK

View Code? Open in Web Editor NEW

This project forked from jupyterhub/jupyterhub

0.0 2.0 0.0 716 KB

Multi-user server for Jupyter notebooks

License: Other

Python 85.65% Shell 0.55% JavaScript 7.48% CSS 1.22% HTML 5.10%

jupyterhub's Introduction

JupyterHub: A multi-user server for Jupyter notebooks

Questions, comments? Visit our Google Group:

Google Group

JupyterHub is a multi-user server that manages and proxies multiple instances of the single-user IPython Jupyter notebook server.

Three actors:

  • multi-user Hub (tornado process)
  • configurable http proxy (node-http-proxy)
  • multiple single-user IPython notebook servers (Python/IPython/tornado)

Basic principles:

  • Hub spawns proxy
  • Proxy forwards ~all requests to hub by default
  • Hub handles login, and spawns single-user servers on demand
  • Hub configures proxy to forward url prefixes to single-user servers

Dependencies

JupyterHub requires IPython >= 3.0 (current master) and Python >= 3.3.

You will need nodejs/npm, which you can get from your package manager:

sudo apt-get install npm nodejs-legacy

(The nodejs-legacy package installs the node executable, which is required for npm to work on Debian/Ubuntu at this point)

Then install javascript dependencies:

sudo npm install -g configurable-http-proxy

Optional

  • Notes on pip command used in the below installation sections:
    • sudo may be needed for pip install, depending on filesystem permissions.

    • JupyterHub requires Python >= 3.3, so it may be required on some machines to use pip3 instead of pip (especially when you have both Python 2 and Python 3 installed on your machine). If pip3 is not found on your machine, you can get it by doing:

      sudo apt-get install python3-pip
      

Installation

As usual start with cloning the code:

git clone https://github.com/jupyter/jupyterhub.git
cd jupyterhub

Then you can install the Python package by doing:

pip3 install -r requirements.txt
pip3 install .

If you plan to run notebook servers locally, you may also need to install the IPython notebook:

pip3 install "ipython[notebook]"

This will fetch client-side javascript dependencies and compile CSS, and install these files to sys.prefix/share/jupyter, as well as install any Python dependencies.

Development install

For a development install:

pip3 install -r dev-requirements.txt -e .

In which case you may need to manually update javascript and css after some updates, with:

python3 setup.py js    # fetch updated client-side js (changes rarely)
python3 setup.py css   # recompile CSS from LESS sources

Running the server

To start the server, run the command:

jupyterhub

and then visit http://localhost:8000, and sign in with your unix credentials.

If you want multiple users to be able to sign into the server, you will need to run the jupyterhub command as a privileged user, such as root. The wiki describes how to run the server as a less privileged user, which requires more configuration of the system.

Getting started

see the getting started doc for some of the basics of configuring your JupyterHub deployment.

Some examples

generate a default config file:

jupyterhub --generate-config

spawn the server on 10.0.1.2:443 with https:

jupyterhub --ip 10.0.1.2 --port 443 --ssl-key my_ssl.key --ssl-cert my_ssl.cert

The authentication and process spawning mechanisms can be replaced, which should allow plugging into a variety of authentication or process control environments. Some examples, meant as illustration and testing of this concept:

Getting help

We encourage you to ask questions on the mailing list:

Google Group

but you can participate in development discussions or get live help on Gitter:

Gitter

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.