Project

General

Profile

Tasks #50490

Updated by Ernesto Puerta over 1 year ago

Replace per distro-packaged dependencies with a common reproducible environment (pip/virtualenv/alternatives for Python). 

 Additionally this could be done by: 
 * Embedding Python code in the repo (via git submodules or subtrees), 
 * Installing at build time via pip (this is the way that Dashboard works for Front-end packages) 

 This would also require modifying the method PyModule::load in the file src/mgr/PyModule.cc to look for packages into the local directory (via sys.path): <mgr_module_path>/site-packages/ (or similar). The default mgr sys path is: 

 <pre> 
 mgr = 
 $WORKSPACE/ceph-api/src/pybind/mgr 
 /usr/lib/python3.8/site-packages 
 /usr/local/lib/python3.8/dist-packages 
 /usr/lib/python3/dist-packages 
 /usr/lib/python3.8/dist-packages 

 $(vstart_pythonpath) 

 /usr/lib/python38.zip 
 /usr/lib/python3.8 
 /usr/lib/python3.8/lib-dynload 
 </pre>

Back