Docker Install: Persistant Extension and Kernel Install

Good afternoon,

I am trying to learn Python as a hobby and have spun up a JupyterLabs instance to go through examples / courses etc.

However whenever I update the Docker image; although my Work folder is persistent my development environments / kernels are not and I also need to reinstall / configure my extensions.

I have tried using Environment Variables to set both JUPYTER_PATH and JUPYTER_DATA_DIR to a sub-directory of my ~/work folder ( as I know this to be persisinat) however although my custom directories are listed under

jupyter --paths

when I update / rebuild the docker image my kernels and installed extensions are overridden.

Any help / advice would be greatly appreciated.