From 50b394ccde622cf647101a4c32bcb88de40686da Mon Sep 17 00:00:00 2001 From: lingyuzeng Date: Thu, 22 Feb 2024 14:56:53 +0800 Subject: [PATCH] add volumes --- jupyterhub_config.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/jupyterhub_config.py b/jupyterhub_config.py index 2cf705a..0c347e9 100644 --- a/jupyterhub_config.py +++ b/jupyterhub_config.py @@ -30,7 +30,14 @@ c.DockerSpawner.notebook_dir = notebook_dir # Mount the real user's Docker volume on the host to the notebook user's # notebook directory in the container -c.DockerSpawner.volumes = {"jupyterhub-user-{username}": notebook_dir} +# c.DockerSpawner.volumes = {"jupyterhub-user-{username}": notebook_dir} +# Mount the real user's Docker volume on the host to the notebook user's +# notebook directory in the container +c.DockerSpawner.volumes = { + "jupyterhub-user-{username}": notebook_dir, + "/mnt/mydrive": "/home/jovyan/work/mydrive" +} + # Remove containers once they are stopped c.DockerSpawner.remove = True