Chapter 8. Creating or importing a notebook in Jupyter
8.1. Creating a new notebook
You can create a new Jupyter notebook from an existing notebook container image to access its resources and properties. The Notebook server control panel contains a list of available container images that you can run as a single-user notebook server.
- Ensure that you have logged in to Red Hat OpenShift Data Science.
- Ensure that you have launched your notebook server and logged in to Jupyter.
- The notebook image exists in a registry, image stream, and is accessible.
- Click File → New → Notebook.
If prompted, select a kernel for your notebook from the list.
If you want to use a kernel, click Select. If you do not want to use a kernel, click No Kernel.
- Check that the notebook file is visible in the JupyterLab interface.
8.2. Uploading an existing notebook file from a Git repository using JupyterLab
You can use the JupyterLab user interface to clone a Git repository into your workspace to continue your work or integrate files from an external project.
- A launched and running Jupyter server.
- Read access for the Git repository you want to clone.
Copy the HTTPS URL for the Git repository.
- On GitHub, click ⤓ Code → HTTPS and click the Clipboard button.
- On GitLab, click Clone and click the Clipboard button under Clone with HTTPS.
In the JupyterLab interface click the Git Clone button ( ).
You can also click Git → Clone a repository in the menu, or click the Git icon ( ) and click the Clone a repository button.
The Clone a repo dialog appears.
- Enter the HTTPS URL of the repository that contains your notebook.
- Click CLONE.
- If prompted, enter your username and password for the Git repository.
- Check that the contents of the repository are visible in the file browser in JupyterLab, or run the ls command in the Terminal to verify that the repository is shown as a directory.