mirror of
https://github.com/jupyterhub/the-littlest-jupyterhub.git
synced 2025-12-18 21:54:05 +08:00
avoid circular imports
This commit is contained in:
@@ -17,7 +17,6 @@ import sys
|
|||||||
import argparse
|
import argparse
|
||||||
from ruamel.yaml import YAML
|
from ruamel.yaml import YAML
|
||||||
from copy import deepcopy
|
from copy import deepcopy
|
||||||
from tljh import systemd, traefik
|
|
||||||
|
|
||||||
|
|
||||||
INSTALL_PREFIX = os.environ.get('TLJH_INSTALL_PREFIX', '/opt/tljh')
|
INSTALL_PREFIX = os.environ.get('TLJH_INSTALL_PREFIX', '/opt/tljh')
|
||||||
@@ -160,6 +159,8 @@ def reload_component(component):
|
|||||||
|
|
||||||
component can be 'hub' or 'proxy'.
|
component can be 'hub' or 'proxy'.
|
||||||
"""
|
"""
|
||||||
|
# import here to avoid circular imports
|
||||||
|
from tljh import systemd, traefik
|
||||||
if component == 'hub':
|
if component == 'hub':
|
||||||
systemd.restart_service('jupyterhub')
|
systemd.restart_service('jupyterhub')
|
||||||
# FIXME: Verify hub is back up?
|
# FIXME: Verify hub is back up?
|
||||||
|
|||||||
Reference in New Issue
Block a user