Hier werden die Unterschiede zwischen zwei Versionen angezeigt.
Beide Seiten der vorigen Revision Vorhergehende Überarbeitung Nächste Überarbeitung | Vorhergehende Überarbeitung | ||
playground:about:coworking:jupyterhub [2025/03/14 14:45] 20.171.207.209 alte Version wiederhergestellt (2025/03/13 02:53) |
playground:about:coworking:jupyterhub [2025/03/30 12:23] (aktuell) 20.171.207.32 alte Version wiederhergestellt (2025/03/14 07:26) |
||
---|---|---|---|
Zeile 1: | Zeile 1: | ||
+ | http:// | ||
+ | |||
+ | offizielle Doku: https:// | ||
+ | |||
+ | Installations PresentationsPDF + Youtube https:// | ||
+ | |||
+ | ===== Jupyter Server aus lokalen Verzeichnisen starten ===== | ||
+ | This launches a Tornado-based Jupyter Server. \\ | ||
+ | '' | ||
+ | '' | ||
+ | Currently running servers: \\ | ||
+ | http:// | ||
+ | http:// | ||
+ | |||
+ | https:// | ||
+ | |||
+ | ===== Hub Installation im lokalen Netzwerk ===== | ||
+ | |||
+ | Anleitung mit eigenem Dockerfile https:// | ||
+ | |||
+ | <note tip> | ||
+ | Hier zum bearbeiten und einbringen von Ideen hochgeladen. | ||
+ | |||
+ | {{ : | ||
+ | |||
+ | </ | ||
+ | | ||
+ | '' | ||
+ | |||
+ | docker build . | ||
+ | |||
+ | < | ||
+ | (base) intrepid-ibex@intrepid-ibex: | ||
+ | [+] Building 1.0s (14/14) FINISHED | ||
+ | => [internal] load .dockerignore | ||
+ | => => transferring context: 2B 0.0s | ||
+ | => [internal] load build definition from Dockerfile | ||
+ | => => transferring dockerfile: 1.23kB | ||
+ | => [internal] load metadata for docker.io/ | ||
+ | => [1/9] FROM docker.io/ | ||
+ | => [internal] load build context | ||
+ | => => transferring context: 38.99kB | ||
+ | => CACHED [2/9] RUN pip install --no-cache | ||
+ | => CACHED [3/9] WORKDIR / | ||
+ | => CACHED [4/9] COPY README.md ./ | ||
+ | => CACHED [5/9] RUN mkdir -p / | ||
+ | => CACHED [6/9] RUN mkdir -p / | ||
+ | => CACHED [7/9] RUN cd / | ||
+ | => [8/9] ADD gitOnline . 0.0s | ||
+ | => [9/9] RUN cd ~ 0.2s | ||
+ | => exporting to image 0.2s | ||
+ | => => exporting layers | ||
+ | => => writing image sha256: | ||
+ | |||
+ | </ | ||
+ | |||
+ | Nun noch folgenden Befehl ausführen um JupyterHub-Server zu starten. | ||
+ | |||
+ | docker compose up -d --build | ||
+ | | ||
+ | Öffne `http:// | ||
+ | |||
+ | ---- | ||
+ | Es gibt verschiedene Methoden um ein JupyterHub Server zum laufen zu bekommen folgend die Notizen des ersten Versuchs. | ||
+ | |||
+ | Auf dem Laptop 💻 | ||
+ | |||
+ | Docker version 24.0.7, build afdd53b | ||
+ | |||
+ | https:// | ||
+ | |||
+ | hostibex: | ||
+ | |||
+ | (base) intrepid-ibex@intrepid-ibex: | ||
+ | |||
+ | REPOSITORY | ||
+ | tljh-systemd | ||
+ | |||
+ | ====== Subdomains ====== | ||
+ | 80.147.0.159 alternativ 185.89.38.58 | ||
+ | * spielwiese.it.bs.fpr.net | ||
+ | * jupyterhub.it.bs.fpr.net | ||
+ | * jupyterhub.itbs.selfhost.co | ||
+ | * jupyterhub.blmgeotest.synology.me | ||
+ | * hub.bergemann-hoehne.com | ||
+ | * ibex.spielwiese.bergemann-hoehne.com | ||
+ | |||
+ | //Zur Server Subdomain würde als erstes die IP 80.147.0.159 mit hub.bergemann-hoehne.com gut passen. | ||
+ | Falls noch eine zweite Subdomain möglich ist sozusagen als Meisterstückadresse wäre ibex.spielwiese.bergemann-hoehne.com super wobei spielwiese auch durch beliebige Domainnamensyntax variabel sein kann. Diese zweite geht auf die IP 185.89.38.58 | ||
+ | // | ||
+ | |||
+ | ==== Authentifikation mit GitHub ==== | ||
+ | |||
+ | https:// | ||
+ | |||
+ | https:// | ||
+ | |||
+ | https:// | ||
+ | |||
+ | benötigt: | ||
+ | - Application name Something users will recognize and trust. | ||
+ | * ibex-tljh | ||
+ | - Homepage URL The full URL to your application homepage. | ||
+ | * http:// | ||
+ | - Application description This is displayed to all users of your application. | ||
+ | * The Littlest JupyterHub Server auf dem IBEX Laptop wenn dieser im Büro-Netzwerk der Synology angeschlossen ist. | ||
+ | - Authorization callback URL Your application’s callback URL. Read our OAuth documentation for more information. | ||
+ | * http:// | ||
+ | |||
+ | |||
+ | |||
+ | Client ID 5fd0150ba241c0c8fde1 | ||
+ | Client secrets f889d2ef26ca21b758db34ae868ecb9a6ddc9b6c | ||
+ | Added Jan 8, 2024 by itbsStefan Never used | ||
+ | You cannot delete the only client secret. Generate a new client secret first. | ||
+ | |||
+ | bearbeite die Konfiguration: | ||
+ | < | ||
+ | sudo tljh-config set auth.GitHubOAuthenticator.client_secret '< | ||
+ | sudo tljh-config set auth.GitHubOAuthenticator.oauth_callback_url ' | ||
+ | sudo tljh-config set auth.type oauthenticator.github.GitHubOAuthenticator | ||
+ | sudo tljh-config reload | ||
+ | </ | ||
+ | |||
+ | ==== Authentifikation zurück setzen ==== | ||
+ | |||
+ | the FirstUseAuthenticator is enabled by default in TLJH. | ||
+ | < | ||
+ | sudo tljh-config set auth.type firstuseauthenticator.FirstUseAuthenticator | ||
+ | sudo tljh-config reload | ||
+ | </ | ||
+ | Users who are currently logged in will continue to be logged in. When they log out and try to log back in, they will be asked to provide a username and password. | ||
+ | Users changing their own password | ||
+ | |||
+ | Users can change their password by first logging into their account and then visiting the url < | ||
+ | |||
+ | Allowing anyone to log in to your JupyterHub | ||
+ | |||
+ | By default, you need to manually create user accounts before they will be able to log in to your JupyterHub. If you wish to allow any user to access the JupyterHub, run the following command. | ||
+ | < | ||
+ | tljh-config set auth.FirstUseAuthenticator.create_users true | ||
+ | tljh-config reload | ||
+ | </ | ||
+ | |||
+ | |||
+ | ---- | ||
+ | $ docker network create --subnet=255.255.255.0/ | ||
====== Startvoraussetzungen ====== | ====== Startvoraussetzungen ====== | ||
intrepid-ibex@intrepid-ibex: | intrepid-ibex@intrepid-ibex: | ||
Zeile 101: | Zeile 248: | ||
(base) intrepid-ibex@intrepid-ibex:/ | (base) intrepid-ibex@intrepid-ibex:/ | ||
3.1.1 | 3.1.1 | ||
+ | |||
+ | $ openssl req -x509 -nodes -days 365 -newkey rsa:1024 -keyout ssltest.key -out ssltest.crt | ||
+ | < | ||
+ | ...............................................++++++++++++++ | ||
+ | ----- | ||
+ | You are about to be asked to enter information that will be incorporated | ||
+ | into your certificate request. | ||
+ | What you are about to enter is what is called a Distinguished Name or a DN. | ||
+ | There are quite a few fields but you can leave some blank | ||
+ | For some fields there will be a default value, | ||
+ | If you enter ' | ||
+ | ----- | ||
+ | Country Name (2 letter code) [AU]:DE | ||
+ | State or Province Name (full name) [Some-State]: | ||
+ | Locality Name (eg, city) []:Berlin | ||
+ | Organization Name (eg, company) [Internet Widgits Pty Ltd]: | ||
+ | Organizational Unit Name (eg, section) []:B&H | ||
+ | Common Name (e.g. server FQDN or YOUR name) []: | ||
+ | Email Address []: | ||
+ | </ | ||
+ | |||
+ | **trusted ssl certificate** ist notwendig ((xsplit)) | ||
+ | Nur mit einer echten Domain kann man Let' | ||
+ | |||
+ | https:// | ||
+ | |||
+ | (base) intrepid-ibex@intrepid-ibex: | ||
+ | Requesting to rerun ./ | ||
+ | [sudo] Passwort für intrepid-ibex: | ||
+ | Skipping bootstrap because certbot-auto is deprecated on this system. | ||
+ | Your system is not supported by certbot-auto anymore. | ||
+ | Certbot cannot be installed. | ||
+ | Please visit https:// | ||
+ | |||
+ | |||
+ | ---- | ||
+ | ibex:/ | ||
+ | $ nano jupyterhub_config.py | ||
+ | | ||
+ | |||
+ | ---- | ||
+ | $ sudo apt install certbot | ||
+ | $ certbot --version | ||
+ | certbot 1.21.0 | ||
+ | |||
+ | | ||