From fd114e9030a606e07a21c60b8643e4961995e896 Mon Sep 17 00:00:00 2001 From: Min RK Date: Fri, 22 Feb 2019 11:17:59 +0100 Subject: [PATCH] use load_config to load config in jupyterhub_config.py rather than re-implementing it --- tljh/jupyterhub_config.py | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/tljh/jupyterhub_config.py b/tljh/jupyterhub_config.py index 61be82e..ff1a34a 100644 --- a/tljh/jupyterhub_config.py +++ b/tljh/jupyterhub_config.py @@ -54,13 +54,8 @@ c.SystemdSpawner.default_shell = '/bin/bash' # Drop the '-singleuser' suffix present in the default template c.SystemdSpawner.unit_name_template = 'jupyter-{USERNAME}' -config_overrides_path = os.path.join(CONFIG_DIR, 'config.yaml') -if os.path.exists(config_overrides_path): - with open(config_overrides_path) as f: - config_overrides = yaml.load(f) -else: - config_overrides = {} -configurer.apply_config(config_overrides, c) +tljh_config = configurer.load_config() +configurer.apply_config(tljh_config, c) # Load arbitrary .py config files if they exist. # This is our escape hatch