-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #6 from lexming/jh12
update configuration files and documentation for deployment of JupyterHub 3.1
- Loading branch information
Showing
8 changed files
with
158 additions
and
221 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -20,11 +20,11 @@ | |
# | ||
### | ||
# | ||
# JupyterHub 2.3 + Oauthenticator + batchspawner | ||
# JupyterHub 3.1 + Oauthenticator + batchspawner + jupyterhub_moss | ||
# based on https://github.com/jupyterhub/oauthenticator/blob/main/examples/full/Dockerfile | ||
# JupyterHub run as non-root user | ||
|
||
FROM jupyterhub/jupyterhub:2.3 | ||
FROM jupyterhub/jupyterhub:3.1 | ||
|
||
MAINTAINER VUB-HPC <[email protected]> | ||
|
||
|
@@ -44,16 +44,16 @@ RUN python3 -m pip install --upgrade pip | |
# install Oauthenticator | ||
RUN python3 -m pip install oauthenticator | ||
# install BatchSpawner and Modular Slurm Spawner (vub-hpc fork) | ||
RUN python3 -m pip install https://github.com/vub-hpc/batchspawner/archive/refs/tags/v1.2.1.tar.gz | ||
RUN python3 -m pip install https://github.com/vub-hpc/jupyterhub_moss/archive/refs/tags/v5.5.2.tar.gz | ||
RUN python3 -m pip install https://github.com/vub-hpc/batchspawner/archive/refs/tags/v1.2.2.tar.gz | ||
RUN python3 -m pip install https://github.com/vub-hpc/jupyterhub_moss/archive/refs/tags/v6.2.1.tar.gz | ||
# install vsc-config | ||
ADD vsc-config /opt/vsc-config | ||
RUN python3 -m pip install vsc-base | ||
COPY vsc-config-master.tar.gz /usr/local/src/ | ||
RUN python3 -m pip install /usr/local/src/vsc-config-master.tar.gz | ||
RUN python3 -m pip install /opt/vsc-config | ||
# install static resources for theming | ||
COPY vub-hpc-logo-horiz-color.png /usr/local/share/jupyterhub/static/images/ | ||
COPY vub-hpc-logo-square-color.png /usr/local/share/jupyterhub/static/images/ | ||
COPY vsc-logo.png /usr/local/share/jupyterhub/static/images/ | ||
COPY assets/vub-hpc-logo-horiz-color.png /usr/local/share/jupyterhub/static/images/ | ||
COPY assets/vub-hpc-logo-square-color.png /usr/local/share/jupyterhub/static/images/ | ||
COPY assets/vsc-logo.png /usr/local/share/jupyterhub/static/images/ | ||
|
||
# --- JupyterHub operator: non-root user --- | ||
# create user with same UID as outside of container | ||
|
52 changes: 52 additions & 0 deletions
52
jupyterhub/container_host/etc/systemd/system/container-jupyterhub.service
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
# Copyright 2023 Vrije Universiteit Brussel | ||
# | ||
# This file is part of notebook-platform, | ||
# originally created by the HPC team of Vrij Universiteit Brussel (http://hpc.vub.be), | ||
# with support of Vrije Universiteit Brussel (http://www.vub.be), | ||
# the Flemish Supercomputer Centre (VSC) (https://www.vscentrum.be), | ||
# the Flemish Research Foundation (FWO) (http://www.fwo.be/en) | ||
# and the Department of Economy, Science and Innovation (EWI) (http://www.ewi-vlaanderen.be/en). | ||
# | ||
# https://github.com/vub-hpc/notebook-platform | ||
# | ||
# notebook-platform is free software: you can redistribute it and/or modify | ||
# it under the terms of the GNU General Public License v3 as published by | ||
# the Free Software Foundation. | ||
# | ||
# notebook-platform is distributed in the hope that it will be useful, | ||
# but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
# GNU General Public License for more details. | ||
# | ||
### | ||
# | ||
# Unit file for a service running a rootless container in Podman | ||
# generated with `podman generate systemd` | ||
# based on: | ||
# - https://www.redhat.com/sysadmin/podman-shareable-systemd-services | ||
# - https://www.redhat.com/sysadmin/podman-run-pods-systemd-services | ||
# | ||
|
||
[Unit] | ||
After=network-online.target | ||
Description=Podman rootless container for JupyterHub | ||
RequiresMountsFor=%t | ||
Wants=network-online.target | ||
|
||
[Service] | ||
Environment="PODMAN_SYSTEMD_UNIT=%n" | ||
ExecStart=/usr/bin/podman run --cidfile=%t/%n/%n.ctr-id --cgroups=no-conmon --sdnotify=conmon --rm --replace -d --read-only --mount=type=tmpfs,tmpfs-size=128M,destination=/home/jupyterhub,chown -v /home/jupyterhub/.ssh:/home/jupyterhub/.ssh:ro -v /home/jupyterhub/.config:/home/jupyterhub/.config:ro -v /home/jupyterhub/.ssl:/home/jupyterhub/.ssl:ro --log-driver=journald -v /dev/log:/dev/log -p 8000:8000/tcp -p 8081:8081/tcp --userns=keep-id --name=jupyterhub ghcr.io/vub-hpc/azure-pipelines-jupyterhub:latest jupyterhub -f /home/jupyterhub/.config/jupyterhub_config.py | ||
ExecStartPre=/bin/rm -f %t/%n/%n.ctr-id | ||
ExecStop=/usr/bin/podman stop --ignore --cidfile=%t/%n/%n.ctr-id | ||
ExecStopPost=/usr/bin/podman rm -f --ignore --cidfile=%t/%n/%n.ctr-id | ||
NotifyAccess=all | ||
Restart=on-failure | ||
RuntimeDirectory=%n | ||
TimeoutStopSec=70 | ||
Type=notify | ||
User=jupyterhub | ||
Group=jupyterhub | ||
|
||
[Install] | ||
WantedBy=multi-user.target | ||
|
Oops, something went wrong.