This repo contains the shared files used to create a JupyterHub server on Digital Ocean using an Nginx proxy server and SSL security. This deployment is for an Engineering Programming class (ENGR114) at Portland Community College during Fall 2019.
Docs for this deployment of JupyterHub in Fall 2019 can be found here:
https://professorkazarinoff.github.io/jupyterhub-ENGR114-2019Q4/
The next most recent deployment of JupyterHub in ENGR101 Winter 2019 can be found here:
Docs for a very similar deployment of JupyterHub in ENGR114 Winter 2019 can be found here:
For another deployment of JupyterHub on Digital Ocean with Nginx proxy. See these blog posts:
https://pythonforundergradengineers.com/why-jupyter-hub.html
- Create SSH public and private keys with PuTTYgen. Save SSH keys in Documents/ssh-keys
- Create a new Digital Ocean Droplet (DO server) running Ubuntu 18.04. Include SSH key when Droplet is created.
- Log into DO server as root with PuTTY and SSH keys. Create a non-root sudo user (username:
peter
). - Log into DO server as non-root sudo user
peter
with PuTTY and SSH keys - Install Miniconda into /opt on the server
- Create a conda env with Python 3.7
- Conda install numpy, pandas, matplotlib, jupyter, notebook, scipy, sympy, pyserial and xlrd
- Conda install -c conda-forge jupyterhub pint
- Run JupyterHub (for just a minute) without SSL to see if it works. Go to the DO server IP address and start a notebook.
- Link Google domain to Digital Ocean DNS servers. In the Digital Ocean DNS dashboard, link domain name to Digital Ocean server.
- Create SSL keys with Let's Encrypt
- Modify jupyterhub_config.py to include SSL keys
- Install Nginx on server
- Modify Nginx config to move traffic to JupyterHub and use SSL cirts
- Run JupyterHub as a system service using systemd
- Restart Nginx and JupyterHub. Should be able to go to https://mydomain.org and start, run and save a Jupyter notebook.
- Add authentication for Google login usernames and passwords
- Create a custom login page
- Pull assignments and notes down from GitHub each time a student logs into JupyterHub.
- Integrate cull idle servers script
- Celebrate!