Home

Awesome

Jupyter

<!-- markdownlint-disable line-length -->

minimal-readme compliant Project Status: Active – The project has reached a stable, usable state and is being actively developed. <a href="https://liberapay.com/benz0li/donate"><img src="https://liberapay.com/assets/widgets/donate.svg" alt="Donate using Liberapay" height="20"></a>

<!-- markdownlint-enable line-length -->

This project serves as a template to run jupyterhub with jupyterlab/r/verse in docker containers using docker compose.
ℹ️ For JupyterHub on a cloud/on-premise k8s environment, see Jupyter's Zero to JupyterHub with Kubernetes.

Screenshot

Features:

The following extensions are pre-installed for code-server:

About:

Table of Contents

Prerequisites

The following is required:

Install

This project depends on the following Docker Deployments:

Usage

  1. Create an external docker network named "jupyter":

    docker network create jupyter
    
  2. Make a copy of all sample. files and folders:

    for file in sample.*; do cp -r "$file" "${file#sample.}"; done;
    
  3. Update environment variables JH_DOMAIN, GL_DOMAIN and JH_CERTRESOLVER_NAME in '.env':

    • Replace mydomain.com with your own domain that serves the subdomain.
    • Replace mydomain-com with a valid certificate resolvers name of Træfik.
  4. Set environment variable JH_COOKIE_SECRET in '.env':
    Generate random cookie secret:

    openssl rand -hex 32
    
  5. Add JupyterHub as an OAuth application in GitLab CE:

    Name: JupyterHub
    Redirect URL: https://jupyter.mydomain.com/hub/oauth_callback
    

    → Replace mydomain.com with your own domain that serves the subdomain.

    • Tick "Trusted"
    • Scopes:
      • Tick "api"
    • Click "Submit" and copy "Application ID" and "Secret"
  6. Update environment variables JH_GITLAB_APPLICATION_ID and JH_GITLAB_SECRET in '.env' accordingly.

  7. Update the following environment variable in 'db.env':

    • POSTGRES_PASSWORD: Superuser password for PostgreSQL (default: password)
  8. Start the container in detached mode:

    docker compose up -d

Test

Wait a moment and visit https://jupyter.mydomain.com to confirm everything went fine.

Reference deployment

Check out the reference deployment at https://demo.jupyter.b-data.ch.

<!-- markdownlint-disable line-length --> <!-- markdownlint-enable line-length -->

Hardened and customised to meet the latest web application security standards.

Further reading

JupyterHub:

JupyterLab:

Similar projects

Contributing

PRs accepted. Please submit to the GitLab repository.

This project follows the Contributor Covenant Code of Conduct.

License

Copyright © 2020 b-data GmbH

Distributed under the terms of the MIT License.

Support

Community support: Open a new discussion here.

Commercial support: Contact b-data by email.

Trademarks

RStudio® is a trademark of Posit Software, PBC, all rights reserved, and may be registered in the United States Patent and Trademark Office and in other countries.

The use of the trademarked term RStudio® and the distribution of the RStudio binaries through the images hosted on b-data's GitLab Container Registry (glcr.b-data.ch) has been granted by explicit permission of Posit Software, PBC. Please review Posit’s Trademark Guidelines and address inquiries about further distribution to permissions@posit.co.