Skip to content

Commit

Permalink
Merge branch 'feature/pcartas'
Browse files Browse the repository at this point in the history
  • Loading branch information
pcartas committed Sep 25, 2024
2 parents c33a8b2 + c1f7cfe commit bc8a384
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion tljh/configurer.py
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ def update_user_environment(c, config):


def update_user_account_config(c, config):
c.SystemdSpawner.username_template = "{USERNAME_PREFIX}{USERNAME}"
c.SystemdSpawner.username_template = USERNAME_PREFIX+"{USERNAME}"


def update_traefik_api(c, config):
Expand Down
4 changes: 4 additions & 0 deletions tljh/installer.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@
INSTALL_PREFIX,
STATE_DIR,
USER_ENV_PREFIX,
HASH_USERNAME,
USERNAME_PREFIX,
)
from .utils import parse_version as V
from .yaml import yaml
Expand Down Expand Up @@ -82,6 +84,8 @@ def ensure_jupyterhub_service(prefix):
python_interpreter_path=sys.executable,
jupyterhub_config_path=os.path.join(HERE, "jupyterhub_config.py"),
install_prefix=INSTALL_PREFIX,
usernames_prefix=USERNAME_PREFIX,
hash_usernames=HASH_USERNAME
)
systemd.install_unit("jupyterhub.service", hub_unit_template.format(**unit_params))
systemd.install_unit("traefik.service", traefik_unit_template.format(**unit_params))
Expand Down
2 changes: 2 additions & 0 deletions tljh/systemd-units/jupyterhub.service
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ PrivateDevices=yes
ProtectKernelTunables=yes
ProtectKernelModules=yes
Environment=TLJH_INSTALL_PREFIX={install_prefix}
Environment=TLJH_HASH_USERNAME={hash_usernames}
Environment=TLJH_USERNAME_PREFIX={usernames_prefix}
Environment=PATH={install_prefix}/hub/bin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
# Run upgrade-db before starting, in case Hub version has changed
# This is a no-op when no db exists or no upgrades are needed
Expand Down

0 comments on commit bc8a384

Please sign in to comment.