Skip to content

JupyterLab runtime environment with Poetry and Docker management.

Notifications You must be signed in to change notification settings

miolab/jupyterlab_poetry

Repository files navigation

JupyterLab in Poetry with Docker

Set up a JupyterLab runtime environment managed by Poetry within Docker.

jupyterlab_poetry_sample_image

jupyterlab_poetry_sample_image


Version Information

  • Python & Poetry

    ➜ docker compose run eda python --version
    Python 3.12.8
    
    ➜ docker compose run eda poetry --version
    Poetry (version 1.8.3)
    
  • Included libraries

    Refer to pyproject.toml for details.

Prerequisites

  • Docker and Docker Compose installed.
  • This repository is primarily intended for Mac environments with Apple Silicon.

⭐ Installation and Usage

  • Clone the repository:

    git clone https://github.com/miolab/jupyterlab_poetry.git
  • Build and start Docker containers:

    cd jupyterlab_poetry
    docker compose build
    docker compose up
  • Open JupyterLab in your browser:

⭐ Adding & Updating Packages

Add packages

docker compose run eda poetry add pyclustering
  • When also specifying a version:

    docker compose run eda poetry add pyclustering@^0.10
    

Preview Updates

docker compose run eda poetry update --dry-run

Update packages

docker compose run eda poetry update
  • After updating, rebuild and restart the containers:

    docker compose build
    docker compose up
    
  • An example procedure is described here.


Additional information

Notes

  • Poetry is used for package management purposes, and the virtual environment venv is avoided.

    poetry config virtualenvs.create false

Uninstallation

To delete environment at once and erase directories, execute the following command.

docker compose down --rmi all --volumes
cd ../
rm -rf jupyterlab_poetry

References

Releases

No releases published

Packages

No packages published