9: 2020-08-21 (金) 18:40:40 iseki |
10: 2020-08-23 (日) 03:36:56 iseki |
| - マルチユーザのための [[Jupyter]] サーバー(ユーザ認証機能つき) | | - マルチユーザのための [[Jupyter]] サーバー(ユーザ認証機能つき) |
| - https://horomary.hatenablog.com/entry/2019/11/09/181614 | | - https://horomary.hatenablog.com/entry/2019/11/09/181614 |
| + | - see also: ''[[Jupyter]]'' |
| #br | | #br |
| | | |
| (jupyterhub) # conda install -c conda-forge notebook -y | | (jupyterhub) # conda install -c conda-forge notebook -y |
| (jupyterhub) # conda install -c conda-forge jupyterlab -y | | (jupyterhub) # conda install -c conda-forge jupyterlab -y |
- | (jupyterhub) # conda install -c conda-forge jupyterhub -y | + | (jupyterhub) # conda install -c conda-forge jupyterhub==1.0.0 -y |
| (jupyterhub) # conda install -c conda-forge voila -y | | (jupyterhub) # conda install -c conda-forge voila -y |
| (jupyterhub) # conda install jupyter_client -y | | (jupyterhub) # conda install jupyter_client -y |
| (jupyterhub) # pip install -e nativeauthenticator (認証モジュール:オプション) | | (jupyterhub) # pip install -e nativeauthenticator (認証モジュール:オプション) |
| (jupyterhub) # pip install dockerspawner | | (jupyterhub) # pip install dockerspawner |
| + | |
| + | - ディレクトリのパーミッションの設定を忘れずに! |
| #br | | #br |
| | | |
| **** jupyterhub.auth.PAMAuthenticator (default) [#n3acea52] | | **** jupyterhub.auth.PAMAuthenticator (default) [#n3acea52] |
| - 認証に[[PAM]]を使用する.恐らくサービスは login | | - 認証に[[PAM]]を使用する.恐らくサービスは login |
- | - バグあり. [[Trouble Shooting>#rf83821d]] 参照. | + | - v1.1.0 にバグあり. [[Trouble Shooting>#rf83821d]] 参照. |
| #br | | #br |
| | | |
| - サーバに,各ユーザの環境でアクセスできる. | | - サーバに,各ユーザの環境でアクセスできる. |
| - Jupiter Notebook はサーバにインストールされている物を使用する. | | - Jupiter Notebook はサーバにインストールされている物を使用する. |
- | - 通常作業ディレクトリは /home/{username}/notebook (notebook は設定による) | + | - 通常作業ディレクトリは /home/{username}/notebook (v1.0.0 はディレクトリ指定にバグが有る模様) |
| + | - 使用ポートは 8000/tcp, 8081/tcp |
| #br | | #br |
| | | |
| - サーバでユーザ毎に ''[[Docker]]'' でNotebook コンテナを起動して接続. | | - サーバでユーザ毎に ''[[Docker]]'' でNotebook コンテナを起動して接続. |
| - 作業ホームは /home/jovjan/work 固定(多分 Docker Image固定) | | - 作業ホームは /home/jovjan/work 固定(多分 Docker Image固定) |
| + | - 使用ポートは 8000/tcp, 8081/tcp, 8001/tcp |
| - Install | | - Install |
| (jupyterhub) # pip --no-cache-dir install git+https://github.com/jupyterhub/dockerspawner.git | | (jupyterhub) # pip --no-cache-dir install git+https://github.com/jupyterhub/dockerspawner.git |
| - DockerSpawner と同じパッケージ | | - DockerSpawner と同じパッケージ |
| - クラスタリング用. | | - クラスタリング用. |
- | - コンテナを Docker-Compose で管理し,複数のサーバー上で実行できる. | + | - コンテナを [[Docker Compose]] で管理し,複数のサーバー上で実行できる. |
| + | - 使用ポートは 8000/tcp, 8081/tcp, 8001/tcp, 2377/tcp, 7946/tcp, 7946/udp, 4789/udp |
| #br | | #br |
| | | |
| ** Trouble Shooting [#rf83821d] | | ** Trouble Shooting [#rf83821d] |
| | | |
- | *** JupyterHub: PAM使用時に 再login するとPAMの認証エラーになる. [#cec1cefc] | + | *** [[PAM]] [#cb278bbe] |
| + | |
| + | **** JupyterHub: PAM使用時に 再login するとPAMの認証エラーになる. [#cec1cefc] |
| - 認証モジュールに jupyterhub.auth.PAMAuthenticator を使用した場合,再Loginで失敗 | | - 認証モジュールに jupyterhub.auth.PAMAuthenticator を使用した場合,再Loginで失敗 |
| -- c.JupyterHub.authenticator_class = 'jupyterhub.auth.PAMAuthenticator' | | -- c.JupyterHub.authenticator_class = 'jupyterhub.auth.PAMAuthenticator' |
| - see: https://github.com/jupyterhub/jupyterhub/issues/486 | | - see: https://github.com/jupyterhub/jupyterhub/issues/486 |
| #br | | #br |
- | *** swarm モードだと v1.1.0 でPAM認証のエラーを起こす. [#e7458157] | + | |
| + | **** swarm モードだと v1.1.0 でPAM認証のエラーを起こす. [#e7458157] |
| + | - 上記バグもこれか? |
| - 1.0.0 に戻す. | | - 1.0.0 に戻す. |
- | -- pip --no-cache install jupyterhub==1.0.0 | + | (jupyterhub) # conda uninstall jupyterhub |
| + | (jupyterhub) # conda -c conda-forge install jupyterhub==1.0.0 |
| #br | | #br |