Create a default python venv in containers
Promoting one idea from @whot on !201 (merged) so it doesn't fall through the cracks:
thought bubble, I wonder if something like this in a default-provided .bashrc
would be an option:
if command -v python3 > /dev/null ; then
python -m venv /tmp/_venv
source /tmp/_venv/bin/activate
fi
i.e. our scripts always run in a venv. On the one hand this will make pip a lot more useful since the vast majority of our pip invocations will just work. OTOH for niche cases like testing different python versions or other specialised invocations it will make it very hard to work around this.
Optionally: FDO_PYTHON_VENV: true
set at container-build time to drop that .bashrc
in place.