Skip to content

Commit

Permalink
Merge pull request #63 from ellisonbg/cleanup
Browse files Browse the repository at this point in the history
Adding cleanup_on_shutdown option
  • Loading branch information
ellisonbg committed Jan 5, 2017
2 parents d01e157 + f4d6e3a commit bd6f014
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
5 changes: 5 additions & 0 deletions host_vars/hostname.example
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,11 @@ install_bash_kernel: true
# `openssl rand -hex 32` and enter between quotation marks below.
proxy_auth_token: ''

# Cleanup single user servers and the proxy on jupyterhub shutdown. Setting
# this to false, will allow jupyterhub to be restarted while leaving the proxy
# and single user servers running.
cleanup_on_shutdown: true

# ------------------------------------------------------------------------------
# Packages
# ------------------------------------------------------------------------------
Expand Down
4 changes: 4 additions & 0 deletions roles/jupyterhub/templates/jupyterhub_config.py.j2
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ c.JupyterHub.cookie_secret_file = u'{{ jupyterhub_srv_dir }}/cookie_secret'
c.JupyterHub.db_url = u'{{ jupyterhub_srv_dir }}/jupyterhub.sqlite'
c.JupyterHub.proxy_auth_token = u'{{proxy_auth_token}}'
c.JupyterHub.confirm_no_ssl = True
{% if not cleanup_on_shutdown %}
c.JupyterHub.cleanup_proxy = False
c.JupyterHub.cleanup_servers = False
{% endif %}

{% if use_oauth %}
c.JupyterHub.authenticator_class = u'oauthenticator.LocalGitHubOAuthenticator'
Expand Down

0 comments on commit bd6f014

Please sign in to comment.