-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Docker distribution #410
Comments
Thank you for opening your first issue in this project! Engagement like this is essential for open source projects! 🤗 |
Thanks for opening an issue @almereyda. |
Right at it. |
Awesome, looking forward to it 🎉 |
I was able to run Jupyverse with this patch diff --git a/images/base-notebook/Dockerfile b/images/base-notebook/Dockerfile
index 07903b94..b05aad79 100644
--- a/images/base-notebook/Dockerfile
+++ b/images/base-notebook/Dockerfile
@@ -42,8 +42,10 @@ RUN mamba install --yes \
'jupyterlab' \
'notebook' \
'jupyterhub' \
- 'nbclassic' && \
- jupyter server --generate-config && \
+ 'nbclassic' \
+ 'jupyverse' \
+ 'fps-auth' \
+ 'fps-jupyterlab' && \
mamba clean --all -f -y && \
npm cache clean --force && \
jupyter lab clean && \
@@ -51,6 +53,12 @@ RUN mamba install --yes \
fix-permissions "${CONDA_DIR}" && \
fix-permissions "/home/${NB_USER}"
+RUN pip install --user -U \
+ https://github.com/jupyterlab/jupyter-collaboration/releases/download/v3.0.0alpha2/jupyter_collaboration-3.0.0a2-py3-none-any.whl \
+ https://github.com/jupyterlab/jupyter-collaboration/releases/download/v3.0.0alpha2/jupyter_collaboration_ui-1.0.0a2-py3-none-any.whl \
+ https://github.com/jupyterlab/jupyter-collaboration/releases/download/v3.0.0alpha2/jupyter_docprovider-1.0.0a2-py3-none-any.whl \
+ https://github.com/jupyterlab/jupyter-collaboration/releases/download/v3.0.0alpha2/jupyter_server_ydoc-1.0.0a2-py3-none-any.whl
+
ENV JUPYTER_PORT=8888
EXPOSE $JUPYTER_PORT
diff --git a/images/base-notebook/start-singleuser.py b/images/base-notebook/start-singleuser.py
index c80339f5..2d85f780 100755
--- a/images/base-notebook/start-singleuser.py
+++ b/images/base-notebook/start-singleuser.py
@@ -6,11 +6,30 @@ import shlex
import sys
# Entrypoint is start.sh
-command = ["jupyterhub-singleuser"]
+command = ["jupyverse"]
-# set default ip to 0.0.0.0
-if "--ip=" not in os.environ.get("NOTEBOOK_ARGS", ""):
- command.append("--ip=0.0.0.0")
+# set default listening host to 0.0.0.0
+if "--host=" not in os.environ.get("NOTEBOOK_ARGS", ""):
+ command.append("--host=0.0.0.0")
+
+# set default host port to 8000
+if "--port=" not in os.environ.get("NOTEBOOK_ARGS", ""):
+ command.append("--port=8000")
+
+# set default jupyterlab.server_side_execution to true
+if "jupyterlab.server_side_execution=" not in os.environ.get("NOTEBOOK_ARGS", ""):
+ command.append("--set")
+ command.append("jupyterlab.server_side_execution=true")
+
+# set default kernels.require_yjs to true
+if "kernels.require_yjs=" not in os.environ.get("NOTEBOOK_ARGS", ""):
+ command.append("--set")
+ command.append("kernels.require_yjs=true")
+
+# set default auth mode to noauth
+if "auth.mode=" not in os.environ.get("NOTEBOOK_ARGS", ""):
+ command.append("--set")
+ command.append("auth.mode=noauth")
# Append any optional NOTEBOOK_ARGS we were passed in.
# This is supposed to be multiple args passed on to the notebook command, on top of jupyter/docker-stacks@996fae12 with these commands: cd images/base-notebook
podman build --format docker -t jupyverse .
podman run --rm -it -e NOTEBOOK_ARGS="--set auth.mode=token" -p 8000:8000 jupyverse start-singleuser.py While it was possible to create and save a notebook which returned upon reopening, it was not possible to replicate server side execution.
Needs further investigation. |
The installation of the collaboration features should probably be their own Also I was unsure which entrypoint to apply, both |
Problem
Wanting to create a new JupyterLab on Jupyverse instance, passing by the conversation in #301, I've found a nice example on how to run the authentication dependency Fief through Docker Compose.
As a Jupyverse user, I am now left to imagine the same for it.
Proposed Solution
Add a section about running Jupyverse in a container to the documentation page
Additional context
This assumes the existence of an example Container image capable of running the Jupyverse collaboration server, best enriched with a useful Compose environment.
JupyterLab has top-level support from Docker, as seen in the official guide Data science with JupyterLab | Docker Docs.
Jupyverse should be similarly easy to employ as the jupyter/docker-stacks.
The text was updated successfully, but these errors were encountered: