How to set jupyterlab to use nexus as pypi(pip) repository

Hi
I’m building custom JupyterLab docker image from official jupyter notebook docker images.
right now, I’m struggling with setting nexus repo as pip repo.
there is no pip.conf file inside jupyter notebook image, and also python which is used by jupyter is conda env so i’m confused where to create pip conf file.

Is there anyone who can help me with setting nexus as pip repo for jupyter?

We build from jupyter/base-notebook and created /etc/pip.conf in our image to point to our own repos and it works fine from notebooks

2 Likes

thank you. @mcrutch

For people who need specific solutions,
We added these lines on our base docker image and it works well.

RUN touch /etc/pip.conf &&
set -x &&
echo -e “[global]\n
index-url={nexus url}
trusted-host={nexus host}” > /etc/pip.conf

1 Like