Hi! I’m building new base images and so finally had a look at JupyterLab 2.1. It looks like the Extension Manger is enabled by default now? Is this intentional, or just a side-product of the large refactor? I ask because it doesn’t seem to be documented.
Since I’m building these bases to run inside Gigantum, it doesn’t make as much sense for the user to configure extensions through the Jupyter UI. I suppose this would be similar to folks running on Binder, JupyterHub or other dockerized Jupyter envs?
We create the user directory at runtime, so to the extent possible, I’d like to avoid needing to create a jupyter config (it’s just one more moving piece). If there were a command-line run-time flag, that’d be a little nicer for my use case. But to recap:
- Is the plan to keep the extension manager enabled by default going forwards?
- If so, what’s the easiest way to configure a jupyterlab isntance to run with extension manager disabled (ideally avoiding writing to user home dir)?
It’s the very first item in the changelog for 2.1: https://jupyterlab.readthedocs.io/en/stable/getting_started/changelog.html#v2-1-0
Display the extension manager in the left sidebar by default. Users will need to acknowledge the disclaimer in the extension manager before using it.
The plan is to keep it visible, yes.
The easiest way to disable extensions at a system level is to create a
page_config.json file disabling those extensions, as documented at https://jupyterlab.readthedocs.io/en/stable/user/extensions.html#settings
You could also run the
jupyter labextension disable ... command for the user in your setup, I suppose.
Sorry - I didn’ see it in the places that I checked, but the changelog is the obvious place to look to answer this question.
I’ll have a look at whether running
jupyter labextension disable as root will disable things for all users. But I also see that I could potentially get around this by setting
JUPYTERLAB_SETTINGS_DIR to a directory that exists at image build time.
Did you ever find an effective way of disabling this for all users?
It’s awesome that I randomly decided to check my messages… as I still don’t have my notifications tweaked well for this forum.
Anyway, yes. We created the following global jupyter config file:
We copy that configuration into the root conda environment like so:
COPY page_config.json /opt/conda/share/jupyter/lab/settings
Tracking down the documentation for that was a little hard for me to sift through, but I’m not sure how to improve things. So, I’m not trying to offer a critique… especially since @jasongrout ALREADY posted a link to this page:
I guess THIS FORUM is one way to improve discoverability of the docs / create cookbook / stackexchange style answers…
Anyway, I thought it was confusing, so I don’t mind more questions if you get stuck. Feel free to DM me if I’m not responsive.