From cf2791494e81f6fcc457bb6aa3f3185c17a7dff8 Mon Sep 17 00:00:00 2001 From: Ayaz Salikhov Date: Fri, 18 Aug 2023 19:16:49 +0200 Subject: [PATCH] Add info about root_dir in docs (#1971) * Add info about root_dir in docs * Add note to running.md as well * Better wording --- README.md | 7 +++++++ docs/using/running.md | 7 +++++++ 2 files changed, 14 insertions(+) diff --git a/README.md b/README.md index ed739a26..94c3db64 100644 --- a/README.md +++ b/README.md @@ -61,6 +61,13 @@ Due to the usage of [the flag `--rm`](https://docs.docker.com/engine/reference/r system when the container exits, but any changes made to the `~/work` directory and its files in the container will remain intact on the host. [The `-it` flag](https://docs.docker.com/engine/reference/commandline/run/#name) allocates pseudo-TTY. +```{note} +By default, [jupyter's root_dir](https://jupyter-server.readthedocs.io/en/latest/other/full-config.html) is `/home/jovyan`. +So, new notebooks will be saved there, unless you change the directory in the file browser. + +To change the default directory, you will need to specify `ServerApp.root_dir` by adding this line to previous command: `start-notebook.sh --ServerApp.root_dir=/home/jovyan/work`. +``` + ## Contributing Please see the [Contributor Guide on ReadTheDocs](https://jupyter-docker-stacks.readthedocs.io/en/latest/) diff --git a/docs/using/running.md b/docs/using/running.md index 20600f84..4d492054 100644 --- a/docs/using/running.md +++ b/docs/using/running.md @@ -65,6 +65,13 @@ Pressing `Ctrl-C` twice shuts down the Server and immediately destroys the Docke New files and changes in `~/work` in the container will be preserved. Any other changes made in the container will be lost. +```{note} +By default, [jupyter's root_dir](https://jupyter-server.readthedocs.io/en/latest/other/full-config.html) is `/home/jovyan`. +So, new notebooks will be saved there, unless you change the directory in the file browser. + +To change the default directory, you will need to specify `ServerApp.root_dir` by adding this line to previous command: `start-notebook.sh --ServerApp.root_dir=/home/jovyan/work`. +``` + **Example 3:** This command pulls the `jupyter/all-spark-notebook` image currently tagged `latest` from Docker Hub if an image tagged `latest` is not already present on the local host.