-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
debian: add .requires for specifying python3 deps
we use dh_python3 to define subvar of ${python3:Depends} as a part of the runtime dependencies of python3 packages, like, ceph-mgr modules named "ceph-mgr-*", python3 bindings named "python3-*". but unlike python3 bindings of Ceph APIs, the ceph-mgr modules are not packaged in a typical python way. in other words, they do not ship a "dist-info" or an "egg-info" directory. instead, we just install the python scripts into a directory which can be found by ceph-mgr, by default it is /usr/share/ceph/mgr/dashboard/plugins. this does not follow the convention of python packaging or debian packaging policies related to python package. but it still makes to put these files in this non-convention place, as they are not supposed to be python packages consumed by the outer world -- they are but plugins. and should always work with the same version of ceph-mgr. the problem is, despite that we have ${python3:Depends} in the "Depends" field of packages like ceph-mgr-dashboard, dh_python3 is not able to figure out the dependencies by looking at the installed files. for instance, we have following "Depends" of ceph-mgr-dashboard: Depends: ceph-mgr (= 17.0.0-12481-g805d2320-1focal), python3-cherrypy3, python3-jwt, python3-bcrypt, python3-werkzeug, python3-routes and in the debian/control file we have: Depends: ceph-mgr (= ${binary:Version}), python3-cherrypy3, python3-jwt, python3-bcrypt, python3-werkzeug, python3-routes, ${misc:Depends}, ${python:Depends}, ${shlibs:Depends}, apparently, none of the subvar is materialized to a non-empty string. to improve the packaging, in this change: * drop all subvars from ceph-mgr-*, as they are all implemented in pure python. * add debian/ceph-mgr-*.requires, it's content is replicated with the corresponding requirements.txt files. * add python3-distutils for distutils, as debian and its derivatives package non-essetial part of distutils into a separate package, see https://packages.debian.org/stable/python3-distutils * add ${python3:Depends} so dh_python3 can extract the deps from debian/ceph-mgr-*.pydist * update the rule for "override_dh_python3" target, so dh_python3 can pick up the dependencies specified in .requires file. * remove the python3 dependencies not used by ceph-mgr from ceph-mgr's "Depends" Signed-off-by: Kefu Chai <[email protected]>
- Loading branch information
Showing
10 changed files
with
41 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
CherryPy | ||
asyncssh | ||
cryptography | ||
Jinja2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
bcrypt | ||
CherryPy | ||
more-itertools | ||
PyJWT | ||
pyopenssl | ||
requests | ||
Routes | ||
prettytable | ||
pytest | ||
pyyaml | ||
ceph-common |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
numpy | ||
scipy | ||
scikit-learn |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
pyyaml | ||
kubernetes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
natsort | ||
CherryPy | ||
pecan | ||
werkzeug | ||
requests | ||
python-dateutil |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
kubernetes | ||
jsonpatch |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
pyOpenSSL | ||
cephfs | ||
ceph-argparse | ||
pyyaml | ||
distutils |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,4 @@ | ||
cephfs python3-cephfs; PEP386 | ||
ceph_argparse python3-ceph-argparse | ||
ceph_common python3-ceph-common | ||
distutils python3-distutils |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters