-
Notifications
You must be signed in to change notification settings - Fork 18
Customizing JupyterHub
NB: This is a draft. Its contents will be moved to cylc-doc or to another repository.
Customizing JupyterHub is a common task, with recurrent threads in the JupyterHub gitter channel, and in their Discourse list. Unfortunately, for some customizations, users may have to edit JupyterHub source code.
The main reference for customizing JupyterHub is its documentation page, in special the part about working with templates.
The c.JupyterHub.logo_file
configuration key in jupyterhub_config.py
customizes the logo. Allowing users
to use their own project logo.
c.JupyterHub.logo_file = '../cylc.png'
JupyterHub provides a form that can be used to override the configured spawner settings.
Example of use cases:
- The network ports available are limited due to firewall; so instead of using random ports, the spawner could allow users to type or choose from a range of ports
- There are multiple environments such as research, production, tests, and the user can choose which environment to use
JupyterHub has a code example showing how to use this feature.
To display notes to users, such as security warnings for example, you could either extend a page of JupyterHub template, or just
set the JupyterHub.template_vars
configuration value.
JupyterHub.template_vars = {'announcement': 'This is PRODUCTION!'}